473,385 Members | 2,003 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.

$try = $_GET["distroMainContent"] -- what $try now equal? - variable problem


If I copy and paste this url into my browser:

http://www.bluecasts.com/index.php?t...ent=prices.php

and I've a simple page with this script on it:

<?php
echo "variable to get $variableToLookFor ";
$try = $_GET["distroMainContent"];
echo " == the server says the variable to get is $try == ";
?>
I want $try to now equal "prices.php"

Why would this not happen?

The server is running PHP 4.3

Feb 18 '06 #1
1 1616
Is this url your website? If not then why would it? The page
"http://www.bluecasts.com/index.php?templateId=PT_distroDemo.txt&distroTitle =priceTitle.php&distroMainContent=prices.php"

doesn't link to your script so there's no $_GET variables available.

Now if you make a page on your own site
http://yoursite/index.php?distroMainContent=whatever
with index.php containing your code then you will see results.
<?php
echo "variable to get $variableToLookFor ";
$try = $_GET["distroMainContent"];
echo " == the server says the variable to get is $try == ";
?>

By the way, you'll need to set $variableToLookFor to something or else
php will throw an error.

Feb 18 '06 #2

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

Similar topics

10
by: Jack | last post by:
How would I add a variable that I will assign to a list of $_POST variables that I extract from a form? My form passes a value for $q. That works fine. What I want to do is run an if/else on it...
8
by: Tom Petersen | last post by:
Here is the code: <SELECT NAME="email" style="font-family: Verdana; font-size: 10pt; " size="1"> <% DO WHILE NOT objRS.EOF strEmail = objRS("email") strLName = objRS("last_name") strFName =...
3
by: PM | last post by:
I'm trying to make a kind of search history containing the 3 last searched words. So I'm using 3 Session Variables: Word1 / Word2 / Word3. In order to get this history working, I need to put the...
2
by: Norman Barker | last post by:
Hi, I have the following template <xsl:template match="midas:Request"> <xsl:variable name="var1" select="string(./midas:DataDescriptorGUID/@GUID)"/> <test> <result1><xsl:copy-of...
9
by: Steven Blair | last post by:
Hi, Here is my problem: This is using Visual Studio 2005 I have a DataSet declared as a public member: public DataSet tmp
3
by: I_AM_DON_AND_YOU? | last post by:
Scenario: I have 10 buttons on the Windows form. All the 10 buttons have lengthy code. I don't want to put Try..End Try Exception Handler in all the 10 procedure handling 10 clicks events of 10...
15
by: tatsudoshi | last post by:
Hello, I have this class http://pastebin.com/807571, where I set some variables on __construct. Originaly I set the $total_? variables when the function showLayout() was called. I know pastebin...
1
by: arjun123 | last post by:
I have got a ASP variable problem. i have the code below contain in my asp program. When I add the variables via another screen I can see them on the web front end but none of the other users...
5
by: Elaine121 | last post by:
Hi. I'm creating a mobile website using wml and php. In wml I have a textfield. I can display the value of the field by using variable correct but when I try to use the variable in a mysql select...
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: 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: 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
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...
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
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
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...

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.