?
Solved

Clearing away the values...

Posted on 2003-02-20
8
Medium Priority
?
222 Views
Last Modified: 2006-11-17
Hi, anyone knows how to clear away values after i accessed the page.

http://localhost/example/edit_profile.php?name=Jon&add=the+world&email=abc@def.com&updateBtn=Update

I don't wan this anymore.
How can I make it just http://localhost/example/edit_profile.php again??

-Rgds-
0
Comment
Question by:G-Force
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
8 Comments
 
LVL 2

Expert Comment

by:laurly
ID: 7992019
are you using post or get in your form?  try using post insted.

laurly
0
 
LVL 6

Accepted Solution

by:
carchitect earned 80 total points
ID: 7993682
hi you are sending values on <a href="">edit profile</a>
which is bad practise instead you use hidden values or direct form variables...
then no need to hide them again they will not appear in URL...
regards
0
 

Expert Comment

by:massDer
ID: 7994900
you could always change the header to change the location.
Header("Location: index.php");
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 1

Expert Comment

by:Amerist
ID: 7998095
Instead of passing your variables through the link, pass them in a form with hidden fields, like this


<FORM METHOD="POST" ACTION="edit_profile.php">
<INPUT TYPE="hidden" NAME="name" VALUE="Jon">
<INPUT TYPE="hidden" NAME="add" VALUE="the+world">
<INPUT TYPE="hidden" NAME="email" VALUE="abc@def.com">
<INPUT TYPE="image" src="/images/submitbutton.gif" border="0" name="updateBtn" id="gifSubmit" value="Update">
</FORM>

Then in the URL you won't see the variables anymore.
0
 
LVL 1

Expert Comment

by:KC_Speedball
ID: 8000574
I think his problem is that anyone has data from him in this way an know hi want this data to be deleted. Thats rarely possible. You can try whether the data is change when you leave the name and change all other variables, but if this do not work there is noch chance to clear that data in database.

http://localhost/example/edit_profile.php?name=Jon&add=0&email=0&updateBtn=Update

0
 
LVL 2

Expert Comment

by:Ray_Adams
ID: 8007996
unset(valuename);
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

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

Developers of all skill levels should learn to use current best practices when developing websites. However many developers, new and old, fall into the trap of using deprecated features because this is what so many tutorials and books tell them to u…
Introduction This article is intended for those who are new to PHP error handling (https://www.experts-exchange.com/articles/11769/And-by-the-way-I-am-New-to-PHP.html).  It addresses one of the most common problems that plague beginning PHP develop…
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
Suggested Courses

719 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