39,323 Topics
| |
hello... i have a question about my final year project.. in my database i want to find 5 maximum values from total of defects from car's body... and the data that i'm found must valid for one year, and after one year (next year) maybe the 5 max values may … | |
Hey Daniweb, can somebody explain to my how to call a value from my database after i logged in? Like i log in with the username and password, then i want on my member page to show what email this user has or any other thing from the database. What … | |
I wanna try my self as an experience. Scenario: I have a member join and member log-in wherein the pass word is encrypted in the database (MySQL) Now let's say he forgot the password it too lazy to just open your email account for just getting the password recovery. What … | |
I create the session variable $_SESSION['SESS_MEM_ID'] within my validateLogin.php file shown here: [CODE] <?php include'db_config.inc'; require_once('InitDB.php'); $error_msg = ''; $error_flag = false; function clean($str) { $str = @trim($str); if(get_magic_quotes_gpc()) { $str = stripslashes($str); } return mysql_real_escape_string($str); } try { $dbh = new PDO("mysql:host=127.0.0.1;dbname=$db", $user, $password); } catch (PDOException $e) { … | |
Hi all, I have an inbox, if i click on the inbox which will display list of mails. now i have next button, if i click on the next button it should be possible to display the next mail with respect to the current opened mail. how to do this … | |
Hello, in process.php, I am trying to display google chart by requesting it using streams, the follwoing code is for requesting the chart: [code=php] header('content-type: image/png'); $url = 'https://chart.googleapis.com/chart?chid=' . md5(uniqid(rand(), true)); $chd = 't:'; for ($i = 0; $i < 150; ++$i) { $data = rand(0, 100000); $chd .= … | |
Hi I added a addslash before submit to database like [CODE]$bio=addslashes($_POST('bio'));[/CODE] it will add a "'" before submit .. and everything working fine .. but at the time of edit/ resubmit this form I am getting the following out put [CODE]This is old\' Line This is new' Line[/CODE] Please help … | |
I have a project im working on that includes an activity stream. I'm working in php and MongoDb (noSql). The site can post articles, users can promote articles or add them to favorites. How may i include these in an activity stream similar to facebook or twitter? Example: Josh, john, … | |
Hello I'm a PHP beginner, and I was looking for the best resource online for learning PHP, and also do recommend certain books for the same. Thanks | |
I am basically creating a registration page. Tell me where I am wrong in this code. [CODE] <?php session_start();session_destroy(); session_start(); if($_POST["regfname"] && $_POST["reglname"] && $_POST["regcname"] && $_POST["regemail"] && $_POST["regphone"] && $_POST["regwebsite"]) { if($_POST["regpass"]==$_POST["regcpass"]) { $servername="localhost"; $username="akshay"; $conn= mysql_connect($servername,$username)or die(mysql_error()); mysql_select_db("akshay",$conn); $sql="INSERT INTO acts(fname,lname,cname,email,phone,website,password)values('$_POST[regfname]','$_POST[reglname]','$_POST[regcname]','$_POST[regemail]','$_POST[regphone]','$_POST[regwebsite]','$_POST[regpass]'); $result=mysql_query($sql,$conn) or die(mysql_error()); print "<h1>you have registered … | |
Hi friends , In one of my web portal there are more than 1000 users . I need a news letter for every week for all these users ... My system ( web account ) crashed when I tried with a for loop . Can you please suggest me a … | |
I'm using cubepoints. It has a module named "paid content". Paid content module hides the post content. User need to pay "X" points to view the page. But this module only hides main content. I mean it hides the content whatever "the_content" loop calls. Here is my problem. I'm using … | |
Trying to set-up a simple email script. Every customer must have a login with an email address. If a potential client wants to email that user, I don't want their email posted where others can see it. So my question is how to I query an email address from the … | |
I have a program that simulates the Powerball Lottery game, i have been working on it for weeks now. My issue is with the quick pick option. when the quick pick numbers match the winning numbers it doesn't show the matches. If the user enters the numbers manually it does. … | |
Hi Guys, Hope you can help me with this little conundrum I'm having currently. My company has a dedicated windows server with heart internet and for means of database interaction, we've been forced to move one of our php sites to there. Everythings great and works fine - except the … | |
I am using TinyMCE textarea. Which will be formatted text How I can insert that formatted text into table (database) as well as print value that I have inserted (formatted text) ? [CODE] mysql_query("insert into emailtemplates (name, messagebody, status) values('".$_POST['frmname']."', '".$_POST['content']."', $status)") [/CODE] [B]where $_POST['content'] is my textarea[/B] | |
Hi, I am new to PHP and looking for a help to develop below idea with PHP, MySql and Jquery. [IMG]http://i39.tinypic.com/2cy2xdu.jpg[/IMG] I want to populate matched people number from database according to dropdown slections. Please check above image to understand what i am talking about. Any help is very much … | |
hi mate. i have problem about REGEX this is my simple code [CODE]<?php $teks="hi whats up? how are you?"; $replace=preg_replace("/(you)/i",'<span style="background:yellow;">\1</span>',$teks); echo "$replace"; ?>[/CODE] what the mean \1 ? its not give effect for my text.. if i change the value to \2, the text has change.. thanks mate! | |
Hello all. I have a bit of a problem. I have a few php pages all encoded utf-8. A MySQL database, where it is possible to have characters like: 'á'é'ú'Å‘'ü' and so on, i have set with phpmyadmin to be utf8_hungarian_ci character encoding. Funny thing is, that when I write … | |
Hello, I have a table with 10 rows. each row has 3 columns. column1 is product name column2 is a drop down box with values from 1to10. column3 is a check box. When the checkbox is checked I would like to get the entire row value (product name, quantity) Can … | |
Hi, I am trying to call a function by "onclick" event of the button. When I do that it shows error message. Can anybody help me out on this so that when I click on the button it should call the function and execute it. My code looks like: -------------------------- … | |
Hi, I am trying to upload file and save data to DB. IN File only 10 row and 5 column data.(normal sample data) File has only 24.0 KB (24,576 bytes) I am using..reader.php and oleread.php to upload file But It taking More than 650MB memory (681574400 bytes) Is any [B]other … | |
Hi, I want to select multiple option using check boxes(all values of checkboxes are come from database 1 ) and insert into the particular table in other database using php form. | |
i have two tables in a single database sales... one is product other is order... i want someones help to know how can i do one operation.... i.e when i click on order i want to subtract that one order from the product table.... can u help me with the … | |
As a newbie at 63, I have learned how to build an SQL database from scratch, interrogate it and present results, but I just cannot wrap my bhead around the following issue. I am in the process of constructing a site that will return a list of suppliers to a … | |
Hi I am using the following code to logout: my logout button calls logout.php [U][B]logout.php[/B][/U] <? session_start(); session_destroy(); header("location:site.php"); ?> This doesnt seem to reidrect to my site.php page, it just loads a blank logout.php page, any ideas? | |
[CODE] <?php $oldumask = umask(0); mkdir($url, 0777); umask($oldumask); $myFile = $url."/index.php"; $fh = fopen($myFile, 'w') or die("can't open file"); $stringData ="lots of things"; ?> [/CODE] Why am I not being allowed to write files to my website, it was recently working, my host had some technical issues yesterday,, and now … | |
Guys, need help again, I cant get my mail script working... here is my code [CODE]<?php require_once "Mail.php"; $from = "Sandra Sender <sender@example.com>"; $to = "Ramona Recipient <recipient@example.com>"; $subject = "Hi!"; $body = "Hi,\n\nHow are you?"; $host = "ssl://mail.example.com"; $port = "465"; $username = "smtp_username"; $password = "smtp_password"; $headers = … | |
Hi all, I'm doing some tests with ajax and php. The below code works when I load the page, but I would like to call it when I click a button. How can that be done? index.php: [CODE]<script type='text/javascript'> $.ajax({ type: "POST", url: "test.php", data: "name=name&location=location", success: function(msg){ alert( "Data … | |
I don't know where I went wrong but I'm generally trying to write a .htaccess file that will redirect all files which end in .tsv to .txt instead. (I don't know why but my extension is insisting on renaming the file back. Which is fine, since it's required by another … |
The End.