Jump to content

Search the Community

Showing results for tags 'textbox'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • Welcome to PHP Freaks
    • Announcements
    • Introductions
  • PHP Coding
    • PHP Coding Help
    • Regex Help
    • Third Party Scripts
    • FAQ/Code Snippet Repository
  • SQL / Database
    • MySQL Help
    • PostgreSQL
    • Microsoft SQL - MSSQL
    • Other RDBMS and SQL dialects
  • Client Side
    • HTML Help
    • CSS Help
    • Javascript Help
    • Other
  • Applications and Frameworks
    • Applications
    • Frameworks
    • Other Libraries
  • Web Server Administration
    • PHP Installation and Configuration
    • Linux
    • Apache HTTP Server
    • Microsoft IIS
    • Other Web Server Software
  • Other
    • Application Design
    • Other Programming Languages
    • Editor Help (PhpStorm, VS Code, etc)
    • Website Critique
    • Beta Test Your Stuff!
  • Freelance, Contracts, Employment, etc.
    • Services Offered
    • Job Offerings
  • General Discussion
    • PHPFreaks.com Website Feedback
    • Miscellaneous

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start





Website URL








Donation Link

Found 9 results

  1. Hi - I want to add to a php form a button which will open a pop-up window with records (names of people) and associated radio buttons. On click on respective name's radio button and SUBMIT, parent form textbox is populated. (list of names will be dynamically be selected fro MySQL table). Any suggestions? Many thanks! IB.
  2. I would appreciate if someone could figure this out or tell me the easiest way to do this. I need a count up counter that appears in a textbox so I can record the time a user is on a page. On a side note, I do have their Start and finish time timestamp recorded in myphpadmin database but I am looking for the easiest (or best) way to do this. Any advice or scripts would be very much appreciated. Thanks in advanced. I did find this counter that works but the numbers appear 0.0.1 if counting up. I don't want to confuse the user. I really want to display to the user how long they was on a certain page. <script> $(document).ready(function() { var time = '00:00:00', parts = time.split(':'), hours = +parts[0], minutes = +parts[1], seconds = +parts[02], input = $('#timeInput'); var timer = setInterval(function(){ seconds++; if(seconds == 60) { seconds = 00; minutes++; if(minutes == 60) { minutes = 00; hours++; } } var newTime = hours + ":" + minutes + ":" + seconds; $('#timeInput').val(newTime); }, 1000); }); </script> <input type="text" name="time" id="timeInput"/>
  3. Hi all, I have a query.... have to get all the attribute names as well as values of textbox in json format. Below is the sample example how can i need to get the output... <form action="" method="POST"> <input type="text" name="someName" id="someId" maxlength="12"> <input type="submit" name="submit" value="Submit"> </form> When i click the submit button, i nedd to get all input types whether it could be textbox / textarea / checkbox / radio button in json format. Example: When i click on submit button, the output will be like these..... {"type" : "text", "name" : "someName", "id" : "someId", "maxlength" : "12"} If any body knows, Please give me some suggention with examples. Thanks in advance....! :'( :'(
  4. I am developing php page, I am struck on one part :banghead: I have 3 dropdown menus. 1) Room Type 2) No of Person 3) Extra Person and a Textbox Now my Issue is, When I select Room type as Executive the amount should be shown on textbox and select "premium" relevant amount should be shown. when I add Extra Person, Rs 500 should be added in textbox. Thanks shamil
  5. hi, count number of words in textbox and then validate that the number of words should be between 400 to 1000. i googled alot... but didn't get an correct answer.... ??? need help!!! with regards, jasmeet.
  6. Hi all, I am making a flight search engine where i am trying to create a autocomplete textbox. I mean when a user starts typing in the textbox, it will show all related data from my database table. I am new to programming and therefore I have adopt a code from online but it doesn't work, I don't know why. Can anyone please help? If you know any other easy way of doing it, please tell me also This is my Javascript code: <script type="text/javascript" src="js/jquery-1.4.2.js"></script> <script type='text/javascript' src="js/jquery.autocomplete.js"></script> <script type="text/javascript"> $().ready(function() { $("#depAirport").autocomplete("autoCompleteMain.php", { width: 260, matchContains: true, //mustMatch: true, //minChars: 0, //multiple: true, //highlight: false, //multipleSeparator: ",", selectFirst: false }); }); </script> This is my html: <form> <label for="depAirport">Deperture airport</label> <input type="text" id="depAirport" name="depAirport" placeholder="Type destination airport" required autofocus> </form> and this is my php: <?php $host="localhost"; // Host name $username="root"; // Mysql username $password="root"; // Mysql password $db_name="airline_database"; // Database name $con = mysql_connect($host,$username,$password) or die(mysql_error()); mysql_select_db($db_name, $con) or die(mysql_error()); $q = strtolower($_GET["q"]); if (!$q) return; $sql = "select DISTINCT departure_airport as departure_airport from depAirport where departure_airport LIKE '%$q%'"; $rsd = mysql_query($sql); while($rs = mysql_fetch_array($rsd)) { $cname = $rs['departure_airport']; echo "$cname\n"; } ?> PLEASE HELP ASAP
  7. Hi, This is a screenshot of the script I'm trying to finish: A simple page, with an upload box, upload button, dropdown menu with directories, text box and a Create button. I can't see what's wrong in the code, as the folder is not getting created. What I'm trying to do is, when the 'Create' button is clicked: Get path from drop down menu Get text from text box Create a new folder in the selected directory (from drop down menu) with the name being the value from the textbox. This is the code: <?php include("login.php"); ?> <!DOCTYPE html> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>FileStore - Upload Files</title> <link rel="stylesheet" href="./CSS/style.css" type="text/css" media="screen, projection" /> </head> <body> <div id="wrapper"> <header id="header"> <div id="header-content"> <strong><h1>FileStore</h1></strong> Upload multiple files at once! </div> <div class="login-info" > <?php if ($isLoggedin === false) { echo ' <form action="" method="POST"> Username: <input name="username" > Password: <input type="password" name="password" size="8"> <input type="submit" name="submit" value="Login"> </form>'; echo "<p align='right'>You are not logged in.</p>"; echo "<b><a href='registration.php'>Register</a></b>"; }else{ echo $welcomeMsg; } ?> </div> </header><!-- #header--> <section id="middle" align="center"> <div id="container"> <br><br> <div id="content"> <strong><h1>Upload files</h1></strong><br><br> <div id="upload-file" > <form action="" method="post" enctype="multipart/form-data"> <input type="file" value="" name="upload[]" multiple> <button type="submit">Upload!</button> </form> <form action="" method='post' > <select name="myDirs"> <option value="" selected="selected">Select a folder</option> </form> <?php include("dbConfig.php"); global $userid; global $up_path; global $sPath; $Username = $_SESSION["username"]; $sql = "SELECT UserID FROM users WHERE Username = '".$Username."'"; $result = mysql_query($sql) or die(mysql_error()); while($row = mysql_fetch_assoc($result)) { $userid = $row['UserID']; } $sPath = realpath("./files/" . $userid ); if (!file_exists($sPath)) { mkdir($folder_path, 0777, true); chmod($folder_path, 0777); } if (chdir($sPath)) { $iterator = new RecursiveIteratorIterator( new RecursiveDirectoryIterator($sPath, RecursiveDirectoryIterator::SKIP_DOTS), RecursiveIteratorIterator::SELF_FIRST); foreach($iterator as $file) { if($file->isDir()) { echo '<option value="'.$file.'">'.$file."</option>\n"; } } echo var_dump($file); } echo "<form action='' method='post' name='dircreation'>"; echo "<input type='text' name='newDir' > "; echo "<input type='submit' value='Create'>"; echo "</form>"; if(isset($_POST['dircreation'])) { $selected_path = $_POST["myDirs"]; $newDir = $_POST["newDir"]; //$fPath = realpath($sPath. "/" . $file . "/"); $folder_path = $selected_path . "/" . $newDir . "/" ; var_dump($folder_path); if (!file_exists($folder_path)) { mkdir($folder_path, 0777, true); chmod($folder_path, 0777); echo "Folder" . $newDir . "created."; echo "Redirecting to upload page.."; // header( 'Location: upload.php' ) ; } else { echo "Error creating " . $newDir; } } else if (isset($_POST['upload[]'])) { $error_message[0] = "Unknown problem with upload."; $error_message[1] = "Uploaded file too large (load_max_filesize)."; $error_message[2] = "Uploaded file too large (MAX_FILE_SIZE)."; $error_message[3] = "File was only partially uploaded."; $error_message[4] = "Choose a file to upload."; $vpath = strlen($userid); $upload_dir = './files/' . (string)$userid . '/'; $num_files = count($_FILES['upload']['name']); if (!file_exists($upload_dir)) { mkdir($sPath, 0777, true); chmod($sPath, 0777); } else { for ($i=0; $i < $num_files; $i++) { $upload_file = $upload_dir . urlencode(basename($_FILES['upload']['name'][$i])); if (@is_uploaded_file($_FILES['upload']['tmp_name'][$i])) { if (@move_uploaded_file($_FILES['upload']['tmp_name'][$i], $upload_file)) { //Great success... echo basename($upload_file) . " has been uploaded. <br>"; //$content = file_get_contents($upload_file); //echo $content; } else { print $error_message[$_FILES['upload']['error'][$i]]; } } else { print $error_message[$_FILES['upload']['error'][$i]]; } } } } ?> </div> </div><!-- #content--> </div><!-- #container--> <aside id="sideLeft"> <div id="menu-x" align="center"><br> <strong>Menu</strong><br><br> <div class="menu"> <ul> <li><a href="index.php">Home</a></li> <li><a href="upload.php">Upload</a></li> <li><a href="files.php">Files</a></li> <li><a href="about.php">About</a></li> <li><a href="help.php">Help</a></li> <li><a href="#">Logout</a></li> </ul> <br style="clear:left"/> </div> </div> </aside><!-- #sideLeft --> </section><!-- #middle--> <footer id="footer"> <strong>FileStore:</strong> A CMT 3315 Project by Brian Livori </footer><!-- #footer --> </div><!-- #wrapper --> </body> </html>
  8. Hi, I recently posted here in this forum and liked some of the responses, so I came back with another question. Anyway, I'm making an "account" page, where a user can change their account details through textbox's. I'm wondering though, is it possible to get the text from their previously entered text and display it so they can edit it? Thanks in advance!
  9. Hi Everyone, I have a text box, with an address which visitors need to copy into another application. I have the text box, this has the text inside. All I need now is a button that says 'copy' and when you click it, wola! However, the real world hasnt worked this way for me . The code I have is; <script type="text/javascript"> function ClipBoard() { if (window.clipboardData) { alert("copied"); window.clipboardData.setData("Text",document.form1.name.value); } } </script> <form name="form1" method="post" action=""> <input name="name" type="text" class="inputtext" onclick="highlight(this)" id="name" value="<?php echo "$contents";?>"> <BUTTON onclick="ClipBoard()">Copy</BUTTON> </form> I dont understand why this wont work... Any help would be greatly apreciated. Thanks.
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.