PHP v.s. ASP include once("*.inc") - [Expert]

P

Pseudonyme

Hi All !

We are proposing a tool that indicates the exact time from the
certified world time servers.

The webmasters are placing the time within their pages. It is free.
The webmasters have all the platforms : mainly PHP and ASP, but, some
other hidden language that few people know.

The point is : (1) "our team totally hate javascripts because we
believe it is consuming to much electricity for the user." (2) "our
team believe that we can save users session times on our servers, and
electricity of our servers".

So, we will not propose :
<script language='javascript' src='http://andersen.times.com/adveruser/
adverpay.php?country=1270331545&time=1236928998'></script>

BUT, we would prefer to propose :
$homepage = file_get_contents(''http://andersen.times.com/adveruser/
adverpay.php?country=1270331545&time=1236928998');
echo $homepage;

The point is that the webmaster would have to include our code in his
hard coding, instead of a light .js

1>> What do you think of that ?

The technical question is : "$homepage and echo $homepage;" is in
PHP, and it works.

2>> Do you know the similar expression in ASP ? and in the other
languages ? even exotic languages ?

$homepage = file_get_contents(''http://andersen.times.com/adveruser/
adverpay.php?country=1270331545&time=1236928998');
echo $homepage;

We personally thank you for the time you took to read this master
piece of problem and we appreciate the time you took to help.

Have a nice and desirable day,

Cougloff
 
M

Michael Fesser

..oO(Pseudonyme)
We are proposing a tool that indicates the exact time from the
certified world time servers.

Nothing special.
The webmasters are placing the time within their pages. It is free.
The webmasters have all the platforms : mainly PHP and ASP, but, some
other hidden language that few people know.

The point is : (1) "our team totally hate javascripts because we
believe it is consuming to much electricity for the user." (2) "our
team believe that we can save users session times on our servers, and
electricity of our servers".

What are you smoking, car tires? There are reasons to prefer a server-
side language over JS in cases like this, but yours is just nonsense.
So, we will not propose :
<script language='javascript' src='http://andersen.times.com/adveruser/
adverpay.php?country=1270331545&time=1236928998'></script>

BUT, we would prefer to propose :
$homepage = file_get_contents(''http://andersen.times.com/adveruser/
adverpay.php?country=1270331545&time=1236928998');
echo $homepage;

The point is that the webmaster would have to include our code in his
hard coding, instead of a light .js

He would also have to include the JS call. Same thing.
1>> What do you think of that ?

The technical question is : "$homepage and echo $homepage;" is in
PHP, and it works.
Sure.

2>> Do you know the similar expression in ASP ? and in the other
languages ? even exotic languages ?
RTFM?

$homepage = file_get_contents(''http://andersen.times.com/adveruser/
adverpay.php?country=1270331545&time=1236928998');
echo $homepage;

You already said that, even with the same typo.
We personally thank you for the time you took to read this master
piece of problem and we appreciate the time you took to help.

Have a nice and desirable day,

You should definitely stop smoking, whatever it is.

Micha
 
C

Curtis Dyer

Michael Fesser said:
.oO(Pseudonyme)


What are you smoking, car tires? There are reasons to prefer a
server- side language over JS in cases like this, but yours is
just nonsense.

Seeing as how JavaScript uses so much power, it must have done a
number on the OP's tires. :)

<snip>
 
J

Johannes Keßler

Hi All !

We are proposing a tool that indicates the exact time from the
certified world time servers.
<snip>

Err, wait.... Writing an E-Mail and using a PC consumes also electricity.
So better you turn it off to avoid a electricity blackout...


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.14 (GNU/Linux)

iEYEARECAAYFAkupwHMACgkQE++2Zdc7EteFlwCgnOXERQwY+gWowCS5FlI+JUB1
CFUAoIw0FKJwdQ62V2orcy6IRSgukbzb
=xftg
-----END PGP SIGNATURE-----
 
P

Pseudonyme

ASP and PHP are much more powerful that internet browsers. The code in
PHP and ASP is read once while million of the browsers would have to
play the javascript (electricity volume). Browsers are little
softwares with low-skills on board. How many times do you have to stop
the browsers processes due to javascript problems ? Flash is fine,
because you avoid scripts based on the browsers applications.

Well ASP Please
..........................

How please to convert
$homepage = file_get_contents(''http://andersen.times.com/adveruser/
adverpay.php?country=1270331545&time=1236928998');
echo $homepage;

INTO ASP

The ASP architecture is different from PHP ... Home to do get the
content of a http page using ASP ?

Have a nice day,
Cougloff
 
E

Erwin Moller

Pseudonyme schreef:
ASP and PHP are much more powerful that internet browsers. The code in
PHP and ASP is read once while million of the browsers would have to
play the javascript (electricity volume).


Nonsense.
Each invocation of a script (request by a client) makes the server
execute the script.

I don't understand your electricity story at all.
Are you saying that letting the server fetch the time is cheaper than
letting the browser do it?


Browsers are little
softwares with low-skills on board.


That is your opinion.
I say most modern day browsers are delicate pieces of softeware.

How many times do you have to stop
the browsers processes due to javascript problems ?


That depends on the quality of the javascript code en the quality of the
browser.
You cannot forbid all knifes because some guy killed with a knife.
Flash is fine,
because you avoid scripts based on the browsers applications.


Flash is dead soon.
I predict in the not too distant future you will see more
javascript/canvas based apps and less Flash.
(ef: Apple stopped supporting it on I-phones.)

Well ASP Please
.........................

How please to convert
$homepage = file_get_contents(''http://andersen.times.com/adveruser/
adverpay.php?country=1270331545&time=1236928998');
echo $homepage;

INTO ASP

The ASP architecture is different from PHP ... Home to do get the
content of a http page using ASP ?

Possibly by stopping to post this question to 2 PHP related newsgroups.

Have a nice day,
Cougloff

You too.

Erwin Moller




--
"There are two ways of constructing a software design: One way is to
make it so simple that there are obviously no deficiencies, and the
other way is to make it so complicated that there are no obvious
deficiencies. The first method is far more difficult."
-- C.A.R. Hoare
 
G

Geoff Berrow

You should definitely stop smoking, whatever it is.

Heh.. exactly what I was thinking. But I suspect a lot has been lost
in translation and in particular in the use of the word 'electricity'.

So the question seems to be, if we want to display the time on a
webpage should we use the server or the client machine?

If we use the client machine we have to assume the clock is set
correctly.

If we use the server, we have to determine the locale of the user.

If it's needed for a critical process, server time should be used. If
it's eye candy why even bother, I have enough sources of time around
me, I don't need it on a webpage.
 
M

+mrcakey

Pseudonyme said:
ASP and PHP are much more powerful that internet browsers. The code in
PHP and ASP is read once while million of the browsers would have to
play the javascript (electricity volume). Browsers are little
softwares with low-skills on board. How many times do you have to stop
the browsers processes due to javascript problems ? Flash is fine,
because you avoid scripts based on the browsers applications.

Wow. Somehow you've picked up some very wrong ideas.

The script would be executed *every time a request was made* to YOUR SERVER
if you did it in PHP and YOUR SERVER would have to fetch the information
from the time servers. If you did it in JavaScript it would be executed on
the USER'S BROWSER (i.e. the client) and THEIR CLIENT would fetch the
information from the time servers.
 
C

C. (http://symcbean.blogspot.com/)

Heh.. exactly what I was thinking.  But I suspect a lot has been lost
in translation and in particular in the use of the word 'electricity'.

No, this is a really dumb idea. There is already a working method for
getting accurate time measurement via the internet - NTP. The nature
of HTTP is that it cannot even come close to the level of accuracy
available even at second stratum time servers. A stratum 0 device can
be acquired for less than 50 USD (although the low cost GPS units
typically only give an accuracy comparable to stratum 1).

At best, the proposal would give an estimate of the time at which the
timestamp was requested. It pre-supposes that the time taken for the
third party to poll the data, generate their own page incorporating
the content and deliver it to the browser is either predictable or
consistent - which is a nonsense.

The business model is as flawed as the interpretation of the
technology. The only people who are going to be interested in this,
are people who can't/won't implement NTP on their servers but think
its important to have accurate time reporting on the browser. i.e. the
majority of the potential customer base can't run serverside scripts.

Also, human beings aren't normally interested in measuring time with
less than about a minutes accuracy - so I fail to see what the benefit
in trying to publish an accurate time is.

Also, judging from the OPs poor but overly enthusiastic english, he
only seems to be asking how to include content from a remote site
within a page generated by Microsoft's asp - which makes it totally
off-topic on a PHP newsgroup.

C.
 
T

Thomas 'PointedEars' Lahn

Geoff said:
So the question seems to be, if we want to display the time on a
webpage should we use the server or the client machine?

Depends. If it needs to be the real time, you should use both.
[...]
If it's eye candy why even bother, I have enough sources of time around
me, I don't need it on a webpage.

ACK


PointedEars
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,007
Latest member
obedient dusk

Latest Threads

Top