Wrox Programmer Forums
| Search | Today's Posts | Mark Forums Read
BOOK: Beginning PHP5, Apache, and MySQL Web Development ISBN: 978-0-7645-7966-0
This is the forum to discuss the Wrox book Beginning PHP5, Apache, and MySQL Web Development by Elizabeth Naramore, Jason Gerner, Yann Le Scouarnec, Jeremy Stolz, Michael K. Glass; ISBN: 9780764579660
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning PHP5, Apache, and MySQL Web Development ISBN: 978-0-7645-7966-0 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
  #1 (permalink)  
Old January 25th, 2006, 07:11 PM
Registered User
 
Join Date: Jun 2004
Location: Walpole, MA, USA.
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default Ch_6 $_SERVER["REQUEST_URI'] causes error

If I use the following code:

  <p align="center" style="color:#FF0000">
    Are you sure you want to delete this <?php
    echo $_GET['type']; ?>?<br>
    <a href="<?php echo $_SERVER['REQUEST_URI']; ?>&do=1">yes</a>
    or <a href="index.php">Index</a>
  </p>

Everything works fine until I click on yes. I then get a Page Not Found error and the following is in my address bar:

http://localhost/Ch_6/&do=1

If I understand what this code should do, I think what I should be getting back is:

http://localhost/Ch_6/delete.php&do=1

Is this error caused by the fact that I'm using localhost? I've gone through the code looking for a syntax error (my most favorite thing to do to myself :)) but I don't see it.

Any help would be much appreciated!

  #2 (permalink)  
Old January 26th, 2006, 09:47 AM
Registered User
 
Join Date: Jun 2004
Location: Walpole, MA, USA.
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Not sure what I did to get this working, but I did get it working.

If anyone can see my error in the code above, please let me know, so I don't make the same mistake again. Thanks!



Similar Threads
Thread Thread Starter Forum Replies Last Post
Parse error: syntax error, unexpected T_ELSE in /h vipin k varghese BOOK: XSLT Programmer's Reference, 2nd Edition 4 September 29th, 2011 01:19 AM
Insert Query Error & Run-Time Error 3022 DavidWE Access 1 July 31st, 2008 11:17 AM
Ch 4: Parse error: syntax error, unexpected T_SL hanizar77 BOOK: Beginning PHP5, Apache, and MySQL Web Development ISBN: 978-0-7645-7966-0 0 June 23rd, 2008 09:17 PM
error in <form action='{$_SERVER['PHP_SELF']} lanita PHP How-To 1 July 27th, 2004 01:07 AM
$_SERVER['HTTP_REFERRER'] natmaster Beginning PHP 1 July 21st, 2003 03:04 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.