Solved

Javascript inside php echo

Posted on 2011-03-16
3
422 Views
Last Modified: 2012-08-13
Hi all,

I need to insert a javascript refresh page into an echo:

history.go(0) in an echo ?

Anyone please?

Thanks

p.s: I basically need to reload the page by code.
0
Comment
Question by:error77
3 Comments
 
LVL 8

Accepted Solution

by:
Rik-Legger earned 500 total points
ID: 35149382
echo '<script>history.go(0)</script>';

Open in new window

0
 
LVL 4

Expert Comment

by:GeoffHarper
ID: 35149409
Do you mean:

location.reload(true);
0
 

Author Closing Comment

by:error77
ID: 35149469
p.s: true: location.reload(true); and it didn't reload the page but thanks anyway for the suggestion.
The jajvascript works perfect. Thanks :o)
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Build an array called $myWeek which will hold the array elements Today, Yesterday and then builds up the rest of the week by the name of the day going back 1 week.   (CODE) (CODE) Then you just need to pass your date to the function. If i…
Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)

789 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question