473,385 Members | 1,341 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,385 software developers and data experts.

how to redirect to a path( a string variable )

dgs
Hi , I am new to php.

i want to redirect a request to a page on my localhost, with some
parameters. how do i do that in php?

i was able to do that in javascript by using "window.location= path"

i tried with cURL, but failed.
Is there any other method ? or what may be likely mistake in my code.

Thanx in advance....

Oct 31 '07 #1
4 2068
dgs wrote:
Hi , I am new to php.

i want to redirect a request to a page on my localhost, with some
parameters. how do i do that in php?

i was able to do that in javascript by using "window.location= path"

i tried with cURL, but failed.
Is there any other method ? or what may be likely mistake in my code.

Thanx in advance....

The easiest way is just to use the header() function.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Oct 31 '07 #2
On Wed, 31 Oct 2007 11:43:06 +0100, dgs <pd****@gmail.comwrote:
Hi , I am new to php.

i want to redirect a request to a page on my localhost, with some
parameters. how do i do that in php?
Redirect the visitor (http://www,php.net/header), or get data from
somewhere and else show that to the visitor (file_get_contents,curl or
http://www.php.net/virtual, or other..)?
--
Rik Wasmus
Oct 31 '07 #3
dgs
On Oct 31, 4:04 pm, "Rik Wasmus" <luiheidsgoe...@hotmail.comwrote:
On Wed, 31 Oct 2007 11:43:06 +0100, dgs <pdu...@gmail.comwrote:
Hi , I am new to php.
i want to redirect a request to a page on my localhost, with some
parameters. how do i do that in php?

Redirect the visitor (http://www,php.net/header), or get data from
somewhere and else show that to the visitor (file_get_contents,curl or http://www.php.net/virtual, or other..)?
--
Rik Wasmus
Thanx for helping me out....
Now my code is working...Thanx a lot

Oct 31 '07 #4
dgs
On Oct 31, 4:01 pm, Jerry Stuckle <jstuck...@attglobal.netwrote:
dgs wrote:
Hi , I am new to php.
i want to redirect a request to a page on my localhost, with some
parameters. how do i do that in php?
i was able to do that in javascript by using "window.location= path"
i tried with cURL, but failed.
Is there any other method ? or what may be likely mistake in my code.
Thanx in advance....

The easiest way is just to use the header() function.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstuck...@attglobal.net
==================
Thanx for helping me out....
Now my code is working...Thanx a lot

Oct 31 '07 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: NotGiven | last post by:
I am sending email using the mail() function on a hosted account. I am trying to override the RETURN-PATH variable but it is not working. The server keeps overriding the variable I put in. ...
1
by: skeeterbug | last post by:
i have a missing path variable in start > system > advanced > environment >system variables. i had to make changes to it when i installed php. the changes were made fine since i verified my...
1
by: Scott | last post by:
I'm trying to concatenate a path of Application("WebSiteFullPath") which equals http://www.mywebsite.com/ and an image file like CODE below. My problem is the full path listing in RESULTS below...
7
by: JS | last post by:
I have a series of pages which make up a questionnaire. It's all done in PHP and I'd like to have two submit buttons (well, images really) so that one submits the form and takes them to the next...
7
by: ColinWard | last post by:
Hello. I use the following line which returns the path of a file and adds it to a listbox. How can I modify this line so that it only returns the filename and not the entire path? -->...
1
by: iana_kosio | last post by:
Hi, I was wondering if I can make an aspx file use the PATH variable to locate dlls that it needs. Currently, it looks as though that the aspx page looks for binaries in a bin folder that is...
1
by: Colmag | last post by:
I remember setting the PATH environment variable from years back, but haven't touched it since win95 days. Now i have to add a couple of lines to it using vb.net so that a console app will work...
21
by: Hitesh | last post by:
Hi, I get path strings from a DB like: \\serverName\C:\FolderName1\FolderName2\example.exe I am writing a script that can give me access to that exe file. But problem is that string is not...
0
by: cnathaide | last post by:
Hi, I have written a simple command line application in C# and created the accompanying setup project in VS 2005. When the user installs the application on the his/her machine, I would like...
6
by: Matthew Wells | last post by:
Hello, I'm trying to make a shortcut that will open an mdb in the same folder as the shortcut - regardless of where the file/shortcut may be. In other words, I wan to be able to copy and paste...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?

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.