Changing Password From Web Page
I have a need to allow a 'email only' user to change their password on the system from my home page. Normally the user does not log in.
1) need them to login to confirm user/pass
2) enable them to change pass using the _passwd_ file.
Since Apache runs as nobody I need a funtion or two to do the above.
NOT using a sql database but just the usual _passwd_ file. using Linix - RH6.0 - Apache with php3_mod I don't mind doing the reading if I know what to read!
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Samba & PHP Password Changing
How I can make PHP script on webpage that first authenticates user (against smbpasswd) and then changes password (executes smbpasswd $user $passwd).
Secure Mail Password Changing Script
Would it be possible to create a script that securely changes one's email password (POP3 inbox) over the web without using a secure server? Is there a way of encrypting stuff before it is sent to the server?
Changing Db Within Page
I have a php page that flips between dbs and sometimes it works and sometimes it doesn't... e.g. the first query runs from this db, the second query runs from a different db and then the third query runs from the first db again... the first query will run, the second query will run, but then the third query will not. Each time that I switch to a query that calls a different db, I used include_once "db_whatever"; before the query, thinking that, that would work, but it doesn't... Is there something I need to do to kill the previous db connection prior to moving onto another one?
Changing Title Of Page
does anyone know how to use PHP to change the title of a page? Let's say my title is currently "GOGOGO" , but I want to add a string "$x" to it so it says "GOGOGO $x", using PHP does anyone know how to do that?
Changing Text On Page Via Dropdown Box.
I have a webpage that draws various text decriptions from a mySql database. The description displayed on the page is controlled via a dropdown box. Currently I am using Javascript with a dropdown box (onChange handler) to change the value of a textbox. Can anybody think of a way that I don't have to use a textbox(with its' scrollbars and background)? How can I change the value of a php variable by changing the selected index of a dropdown box?
Changing The Variable As You Pass It Through To The 2nd Page
I am using a form to push variables through to another page. In the form, (a drop down), the code is: <select name="1"><option>L</option><option>P</option></select> Now on the second page I could display the P or the L by saying <?php echo $1 ?> which is fine. What I want is, if someone selects P then it prints 1 on the next page and if they select L then it prints 2. Is this possible?
Changing A More Link Into Page Numbers
I have the following code which I've tried to edit to fit some examples others have posted on here, with no luck. I have a page that displays More and Prev links but not the page numbers. How can I change this code to have page numbers instead of the More Prev? PHP Code:
Access A Secure Page By Changing The Url
how can i stop people getting into a secure logged in page by just typing www.somesite.co.uk/admin/index.php. theres a login set up, but i can bypass it by just entering the url location, this is a major security issue that i need to solve relatively quickly before i publish the pages. what i need/want is if someone isn't logged in it just goes to a page saying "you must be logged in to access this page" then prompts them to login.php.
Changing Titles Per Page With Inc Files.
The way my script is set up now, I have an index.php which calls on inc files. The problem is that each page (inc file) is using the title set in the php.index. My goal is to have a title for each page. I've looked and looked but can't find anything.
Changing An If Statement To Html Page
How do I change the following code from my process page to a new page with the detials on it. I made a html page cut and pasted it into this spot but it did not work. What do I need to change in order for it to be a html page is shows. Code:
Changing Pictures On Index-page When Reloading
I am a beginner but quite curious anyway. My problem: I have seen websites that show different pictures whenever you enter the site. By doing this, the sites look always fresh and attractive and I like the idea a lot. Now I like to have the same function on my site but I do not know how that works... Is there anybody who can give a good "explanation for dummies" on how to do that?
Password Protected Page
I try loging in and it brings me back to the same page or it tells me my session id can't be used. Here is the password code i used. Code:
Help Implementing A User And Password Page
What I want to so is to restrict acces into a page, I was thinkin something as simple as this, having a Database in Mysql with fields user and pw use a kinda command like "where user='$user' and pword='$pword'" if the two fields match send the user to a webpage like admin.html, and the last thing how can I encript or hide the displayed url or page? like www.example.com/ or symbols etc... so a user cant cunsult the page jumping the loggin page? Thanx allot, by the way, Im starting at this php and mysql, so please try to be the most explicit Ill apreciate it.
PHP Code To Access Password Protected Page
I have written the following HTML/PHP code to validate and provide access to a password protected page to users who are given the user ID and password through a separate e-mail. The required page, Articles.html, however does not load when the valid user ID and password is provided. Instead, the response is a blank page. validate.php <html> <head> <title>Login Authentication</title> </head> <body> <?php if (($_POST["username"]=='cutedog')AND($_POST["password"]=='puppy')) { header("Location: http://www.domain.com/Articles.html"); exit(); } else { echo "Login denied to the page - Articles.html"; } ?> </body> </html> Does any other file need to be included for HEADER function to work? I currently do not have CGI or SSI active on my hosting account. I am using the following HTML form for the user to submit the user ID and password to access the password protected page. <html> <head> <title>code</title> <script LANGUAGE="javaScript"> <!-- function validateForm() { with (document.saveform) { var saveit = true; if (username.value.length < 4) { alert ("Username too short. The username must be at least 4 characters in length."); username.focus(); username.select(); saveit = false; } if ((password.value.length < 4) && saveit) { alert ("Password too short. The password must be at least 4 characters in length."); password.focus(); password.select(); saveit = false; } else if (saveit) submit(); } } //--> </script> </head> <body> <form ACTION="http://www.domain.com/validate.php" name="saveform" METHOD="POST" align="center"> <div align="center"><center> <table border="0" width="93%" cellspacing="0" cellpadding="0"> <tr> <td width="52%"><div align="center"><center><table border="0" height="59" width="310" bgcolor="#808080" cellspacing="1" cellpadding="0"> <tr> <td width="248" height="19" bgcolor="#C0C0C0"><div align="right"><p><font color="#000000"><small>Add Your test username:</small></font></td> <td width="123" height="19" bgcolor="#C0C0C0"><div align="left"><p><input NAME="username" VALUE SIZE="8" MAXLENGTH="16" tabindex="1"></td> <td width="47" height="19" align="center" bgcolor="#C0C0C0"><div align="center"><center><p><a href="javascript:alert('The username must be between 4 and 16 characters long.')"><small><small>Help</small></small></a></td> </tr> <tr align="center"> <td width="248" height="17" bgcolor="#C0C0C0"><div align="right"><p><font color="#000000"><small>Add Your test password:</small></font></td> <td height="17" width="123" bgcolor="#C0C0C0"><div align="left"><p><input type="password" name="password" size="8" tabindex="2" maxlength="8"></td> <td width="47" height="17" align="center" bgcolor="#C0C0C0"><a href="javascript:alert('The password must be between 4 and 8 characters long.')"><small><small>Help</small></small></a></td> </tr> <tr align="center"> <td width="248" height="1" bgcolor="#C0C0C0"></td> <td width="123" height="1" bgcolor="#C0C0C0"><div align="left"><p><input TYPE="button" NAME="FormsButton2" VALUE="submit" ONCLICK="validateForm()" tabindex="3"></td> <td width="47" height="1" align="center" bgcolor="#C0C0C0"><a href="javascript:alert('Click to save the details')"><small><small>Help</small></small></a></td> </tr> </table> </center></div></td> </tr> </table> </center></div> </form> </body> </html>
WWW-Authenticate: How To Force Password Login At Every Page Refresh ?
<!-- The following sample should authorize the user to log on the site. This works once but after refreshing the browser, it does not prompt again for login until all browser (IE 6) windows are closed and the same page is opened. I turned off all caching but still it does cache (as a refresh doen not promt again). How can I force the page to prompt for a password at every refresh --> <html> <head> <META HTTP-EQUIV="PRAGMA" CONTENT="NO-CACHE"> <META HTTP-EQUIV="CACHE-CONTROL" CONTENT="NO-CACHE"> <?php $showall = false; error_reporting (E_ERROR); if (($PHP_AUTH_USER != "myname") || ($PHP_AUTH_PW != "mypass")) { header('WWW-Authenticate: Basic realm="Secure Login"'); header('HTTP/1.0 401 Unauthorized'); $showall = false; } else { error_reporting (E_ALL ^ E_NOTICE); $showall = true; } if (!showall) { echo "access denied"; } else { ?> ................ </head> <body> ................. <? } ?> </body> </html>
Authenticate A User Using Same Password As Linux Password
We're working on an intranet site where we will require user's to only be able to access their own page in some instances. Rather than introducing another password to the mix, we were thinking about seeing if we could use the same credentials (username and password) as their linux credentials. The web site will be running off of the same machine that we want to access the credentials on.
Password Protect Pages With The Same Password For Every User.
I am building a site where every user has to enter a password to go to the next page. The passwords will be the same for everyone. So for example, to go from page A to B everyone has to type the word "swordfish" into a box at the bottom of page A And to then go from page B to C everyone as to type "afghanistanbananastan" at the bottom of page B etc. Is this something I would use php to do and if so how? I don't want people to be able to view the source and see the passwords.
How To Hide Password In Password Field
I have a .html form which is used get input from user name, password then I will add these username and password into a table (add users). However in this form, I can not hide charactors in the password field. Could you please tell me how to hide this charactors (for example when I type "abcde", it becomes *****). ( I will use a PHP file to grap this information (username and password) and insert it into a mySQL table)Code:
Changing Php.ini
is there a way to change values in php.ini (like adding support for certain things) if you are not hosting your site yourself, like using a pay host?
Changing Passwords
I'm using proftpd with mysql, it's working great. I creaded a site that a proftpd user can use to change his password, I also wrote another PHP script that monitors passwords and if a password is about to expire (90 days), it sends out an email to the user. Now, what I need help with is when a user enters a new password, I don't want this new password to match his previous 6 passwords.
Changing The From Name In Mail()
I know how to send mail with the mail() function. I have looked at the documentation for php and I can not seem to get the right syntax for changing the return name. I am sending mail from my server and it uses the nobody user for the admin of apache. because of this all mail comes in from "nobody". This is really annoying me and if anybody knows the syntax I would sure appreciate it.
Changing Colors
I have this form where you can submit a DJ line up for an event. I want the user to be able to change the font color whenever they wish, and when they hit enter, for it to skip a line. I would like the to be able to do this without them knowing how to use the <br> and <font> commands. Kind of like you see on a phpBB board or something But is there a way to make this button, and when the click it, it keeps the text that they have already entered into the textarea adds a [ i ] or whater and then when they click the button again, it inserts the [/ i ] without altering the text they already typed. it would be much like the buttons you use to do your PHP and color changes in this forum, but without the pop-up window to enter your code into.
Changing Date?
In MySQL database the date format is as follows: YYYY-MM-DD But how can I make it so that when I see it on the page it will be as follows, which is English format: DD-MM-YYYY
Changing The ROOT_DIRECTORY
I am using XAMPP (latest version) I have got MySQL, PHP, Apache etc.. I wanted to change the root directory shown in PHPINFO(); for XAMPP for my localhost:// Is there an easy way to do this? i am a complete novice and first timer and I assume that if I change it to 'C:web' my php files (in that directory will be shown)
Changing Between Times
does anyone know to convert a time string in the form dd-mm-yyyyThh:mm:ss i.e 2006-08-01T15:45:11-00:00 to a normal unix time stamp or something that at least I can use to compare to a unix timestamp.
Changing Php3.ini !!
I need to enable magic_quotes_gpc. I have learned to get to php3.ini through FTP, have changed it's value, and uploaded the file again. However, the value does not seem to change. I am running a dedicated server, and have attempted to reboot the server. Any ideas to why the settings won't change? Could permissions be a factor?
Changing Session Name
Anyone know how vBulletin changes their session name from the default PHPSESSID to just a simple 's', I thought it would just be a case of: PHP Code:
Changing A String
I've got a form to upload a file. When a file is submitted I need to change the file name before I add a reference of it to the database or copy it to a location on the server. So let's say I submit the file "test.txt" I need change the file name to "test revision 1.txt" So I need to find the last instance of "." then move back 1 space and add " revision 1" to the string. Anyone know which functions I would have to use?
Changing The Location Of Php.ini
Does anybody know how to change where PHP looks for the php.ini file? It currently looks for the .ini file in /usr/local/lib. I need to change this so it looks at /home/john/usr/local/lib.
Changing Sizes
I have included the content on my site from another file and want the divide to automatically adjust its self to the size of the included content. In internet explorer this is not an issue, however in Firefox, Opera and I suspect Mozilla, the content overflows and the divides of the page do not automatically adjust.....
Changing Tables
I have my main index.php page and I've been looking around for the simplest way to do this but haven't been able to find anything that suits the purpose. Perhaps you guys can help, since you're the best.. All I want to do is switch the table that is in the middle of the page that displays the content of the page. So if someone clicks on, for example, index.php?files it'll change the table to the files table that I have in an html file or something.
Changing Header
I have a website that I need to change the Header and center it. How do I do that? The files are in the CMS files.
Changing Linebreaks To <BR>
When submittin a form, is there a way to change linebreaks to a <BR>? I know you can use ereg_replace() to replace certain characters, or set of characters, but how to specify a line break?!?
Changing Permission
I have been working with uplaoding of images which creates the folder automatically during uplaoding, but iam unable to change the permission of the folder. when i try changing from cpanel i get the below error. "a fatal error or timeout occurred while processing this directive" Kindly suggest me where iam wrong.
Session Id Keeps Changing
--when i set session.cache_limiter = private i get this Set-Cookie: PHPSESSID=61fdf683fef689d5371a1c01fd46e678; path=/; secure Expires: Thu, 19 Nov 1981 08:52:00 GMT No idea where it's pulling that date from. (Clearly already expired) --when i set session.cache_limiter = private_no_expire i get this Set-Cookie: PHPSESSID=61fdf683fef689d5371a1c01fd46e678; path=/; secure (no Expires line) But my session ID still changes every time i refresh the page. What do I have set wrong? php.ini [Session] ; Handler used to store/retrieve data. session.save_handler = files session.save_path = /tmp session.cookie_secure = 1 session.use_only_cookies = 1 session.name = PHPSESSID session.auto_start = 0 session.cookie_lifetime = 0 session.cookie_path = / session.cookie_domain = ;session.serialize_handler = php session.serialize_handler = wddx session.gc_probability = 1 session.gc_divisor = 100 session.gc_maxlifetime = 1440 session.bug_compat_42 = 0 session.bug_compat_warn = 0 session.referer_check = session.entropy_length = 16 session.entropy_file = /dev/random ;session.cache_limiter = nocache session.cache_limiter = private_no_expire session.cache_expire = 180 session.use_trans_sid = 1
Changing Titles
What I'm trying to do is have a different title per article written on my website. The way the site is run now, the server calls on an include file, but the browser still reads it as the title for the index.php.
Changing To HTML?
I have a piece of text which is entered into my database, this text contains HTML. When I output it onto the page I want the HTML to turn into HTML and do what it is supposed to do, instead of just being normal text. How would I do this?
Redirecting And Changing The URL
I have a login page which remembers what you were trying to access, then uses header('Location: url here') to redirect the user back to what they were trying to access after a successful password. However, the URL remains my.domain.here/login.php, instead of where they were redirected to... which breaks my relative links if they are redirected to a page within a subdirectory.
Changing From Alphabetical
I have had a developer to create a back end for my website. I can't get hold of him, and to be fair I have bothered him enough, as I am trying to learn as well That was not his job to teach me!! What I have is three pictures and text title sitting next to each other, and they are in alphabetical order...What I want to do is place the picture and text title in a different order. Code:
Changing An Array Name.
If I have an array called my_array1, how do I call it within a for cycle? Something like this: for($a=1;$a<=5;++$a){ $my_array = 'my_array'.$a; //prints $my_array } I know that doesnt work, so, I tried something like the following: for($a=1;$a<=5;++$a){ $my_array = 'my_array'.$a; //prints $$my_array } That does work with variables, but doesnt work with arrays. I know that in Java and ActionScript what I'm trying to acomplish is pretty simple, but I cant seem to find the correct syntax for php.
Changing Timezones
I have the date being pulled in an echo statement but I'm trying to use the date_add() function somewhat unsuccessfully... Declaring the current time... <?php $time = date("h:i A"); ?> and then echoing it.. <?php echo $time date_add(INTERVAL 2 HOUR)"; ?> And as guess, it isn't working and even after searching on google, I can't seem to get this one.
Changing The Extention
i just added the following to the htacess file on the server to get php5 working AddHandler x-httpd-php5 .php problem is when i try to open the dir on the localhost it will not open. ive tryed deleting the htacess file but this does not help. The message is "you have chosen to open which is a :application/xhttp-php from http://localhost what should firefox do with this file?
Changing File Name
I'm trying to upload a file, assign it a random name and then reference it too a database. I am using the following script to achieve this but its not working, when I run it all I get is my own error message "Sorry, there was a problem uploading your file.". It is however putting a random number into the databse but it is not adding the extinsion type back on. Code:
Changing File Name
I'm trying to upload a picture and also reference its location to a mysql database. When the file is uploaded I want it to change its name to something random (with no spaces). I have the following script but when I run it it says QuoteSorry, there was a problem uploading your file. Code:
Changing Variables
i have some code that a form sends data to (this part works) i have it so if they order 2 or more the price is different to if they just order 1 ( a discount.)But if any of the boxes are left at zero(0) it still charges them a small fee. And when i try to change a variable in an if statement it does not work. Code:
Changing From ASCII To Binary
How do I change my upload from ASCII to Binary? it was a suggestion to get excel files to upload, but I don't know how to make the change.
Changing Sendmail_from Without Modifying Php.ini
i just switched my site over to a new server and the current domain it sends emails from when i use the mail() function is just "Apache". is there anyway i can change this using the mail() function or something else without modifying the sendmail_from module setting in the php.ini file.
|