473,395 Members | 1,730 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

going back to previous page

29
Hey ... how is everyone ...

I want to put a button on a page that does a "back to previous page" using

a href="<?php $_SERVER['HTTP_REFERER'] ?>" />

attached to the button but it doesn't work. Do I have an error in syntax?

Thanks for your help

Robert
Mar 20 '08 #1
5 2245
aktar
105 100+
Hey ... how is everyone ...

I want to put a button on a page that does a "back to previous page" using

a href="<?php $_SERVER['HTTP_REFERER'] ?>" />

attached to the button but it doesn't work. Do I have an error in syntax?

Thanks for your help

Robert

with PHPs short tags you can do something similar to what youv'e done, which is: [PHP]<?=$_SERVER['HTTP_REFERER']; ?>
[/PHP]

which is the same as :
[PHP]<?php

print $_SERVER['HTTP_REFERER'];

?>[/PHP]

On PHP5 short tags are off by default, so you will need to do it the traditional way.

Dont forget the semi-colon (;)
Mar 20 '08 #2
rlm51
29
Thanks very much ...

As Always ... I love this forum.

Robert
Mar 20 '08 #3
ronverdonk
4,258 Expert 4TB
Thanks very much ...

As Always ... I love this forum.

Robert
We all do!

Ronald
Mar 21 '08 #4
dlite922
1,584 Expert 1GB
We all do!

Ronald
...otherwise we wouldn't be here! ^_^

DM
Mar 21 '08 #5
Markus
6,050 Expert 4TB
with PHPs short tags you can do something similar to what youv'e done, which is: [PHP]<?=$_SERVER['HTTP_REFERER']; ?>
[/PHP]

which is the same as :
[PHP]<?php

print $_SERVER['HTTP_REFERER'];

?>[/PHP]

On PHP5 short tags are off by default, so you will need to do it the traditional way.

Dont forget the semi-colon (;)
As is always said: do your best not to use short tags - it may cause alot of hassle when migrating from one server, with short tags on, to another server, with them off.

[php]
<?php echo $_SERVER['HTTP_REFERER'];?>
[/php]
I'm surprised im the first person to say this, actually.

We all do!

Ronald
Yes, yes we do.

Retards, markus.
Mar 21 '08 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

8
by: Ralph Freshour | last post by:
Is it possible to inhibit the browser Back/Fwd buttons via PHP? Thanks...
25
by: KK | last post by:
Hi, I am using history.go(-1) for implementing the back button functionality. Its working fine but with this exception. 1. The page which is having back button has some hyperlinks on it. ...
4
by: Bratislav Jevtic | last post by:
hi, ASP.NET, framework 1.0, patch 2, Windows 2000 server is this possible: from server side to say "go back" to browser? ------------------- scenario: I've got some page with a list. When...
8
by: moondaddy | last post by:
Is there a way to make the browser move back to the previous page via code behind on the server? The effect would be the same as the user clicking on the browser's back button. Thanks. --...
4
by: tshad | last post by:
I have a logon page that is getting the previous page in its return URL ("logon.aspx?returnURL=A.aspx") where A.aspx is the page that called B.aspx. It should have B.aspx. I am calling B.aspx...
2
by: wiewiek | last post by:
Is there a way to go back to the previous page when a button (Cancel button) is hot? It's an ASP control. Thanks
6
by: Nad | last post by:
Hello, In order to go back to the previous page from a page with possible postbacks I keep Request.Referrer in ViewState and then use it to redirect to the previous page. However I am losing all...
2
by: monomaniac21 | last post by:
hi all im trying to write a pdf document which contains two columns of data. when the column on the left crosses over to the next page i need to be able to go back afterwards to the previous...
3
by: adarshyam | last post by:
friends, i have a problem in going back to previous page in my application.. since i want that to happen in the if else statement i cannot incorporate JS. please help me .. i am trying this...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.