39,316 Topics

Member Avatar for
Member Avatar for nizam27391

Hi. Anybody dealt with cakephp? I have this problems. The delete function is not functioning. Its not deleting the things I want to delete from the database. Heres my code./ [CODE] function delete($id = NULL){ $this->Application->delete($id); //-->this cause problems $this->Session->setFlash("Application " . $id . " was deleted"); $this->redirect(array('action' => 'index')); …

Member Avatar for jmichae3
0
241
Member Avatar for Ingska

Hi! I have some forms that i have used to send to my e-mail using the php mail() function. I have had som issues with it because the mailservice i am using is not on the same server as the domain, so now i am forced to change the way …

Member Avatar for NameSet
0
227
Member Avatar for rse

Hello, How can I encrypt and decrypt a session variable using salt, what do I need to set in the header? I tried this but got error about unknow function mcrypt_ecrypt. Any ideas to help. [code=php] function encrypt($text, $SALT=null) { $SALT=SECURE_KEY; return trim(base64_encode(mcrypt_encrypt(MCRYPT_RIJNDAEL_256, SALT, $text, MCRYPT_MODE_ECB, mcrypt_create_iv(mcrypt_get_iv_size(MCRYPT_RIJNDAEL_256, MCRYPT_MODE_ECB), MCRYPT_RAND)))); } …

Member Avatar for rse
0
47
Member Avatar for siva28

i need a solution... create a web page using send mail option. so mail send to mail id as well as to mobile. also i login through mobile. when i enter using mobile automatically enter my area of web page. is this possible? for example..im client of one website. using …

Member Avatar for jmichae3
0
203
Member Avatar for cmps

Hello, I want to know if I am doing a list of students, which are executed from database (mysql), does the number of data influence in the speed of the page load? if yes: What to do ? And for how much data should I start to think for a …

Member Avatar for cmps
0
128
Member Avatar for rayidi

Dear Friends, I'm developing a website that can show online users, When ever a user logged we can update the status to "Online" On our database. Now i'm using AJAX. Is it possible to show the online users without refreshing a page ? That means timed interval for a ajax …

Member Avatar for makman99
0
166
Member Avatar for jwhite68

Hi I have a script in PHP prepared by a third party some time ago, and when I open it up in Dreamweaver, it just looks a mess. I am not so familiar with Dreamweaver, but is this just a setup issue? Do I need to import all the files …

Member Avatar for diafol
0
145
Member Avatar for Gobble45

Hey guys, only new to Daniweb, so pardon me, if i seem too "nooby" for you guys. I am building a website, and currently am working on the "members area" i have a database named "users" with fields "name", "username", "email", and "password". i am running a php script, and …

Member Avatar for simplypixie
0
255
Member Avatar for opjjuly

Hey guys, Im trying to code a body shape calculator using PHP maths functions, its giving me a headache:confused:. I have tried coding the body shape calculator with the following values, but it jus gives undesirable results:yawn:. Is it my code or the problem is with the ratios? [B]Apple:[/B] 0.8 …

Member Avatar for blocblue
0
160
Member Avatar for Poonam Jadav

hello i am a student ane new to php i have a code here i want to pass the data from one page to another but i m not able to do so plz check both the code and please help [CODE] <html> <head> <title>update_tanenet</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <link …

Member Avatar for simplypixie
0
124
Member Avatar for jsrpatna

Hi All, I've this problem with cookies. I am lost as I can't understand why this code does not work as expected. Please help!! [CODE] $rq =$_REQUEST['r'] ; $value = $_REQUEST['v']; setcookie("XYZ",$value, time()+60*60*24*30) ; echo "Value is ".$value; if ($rq =='showdata'){ print_r($_COOKIE); echo "Cookie is".$_COOKIE['XYZ']; exit; } [/CODE] Output: when …

Member Avatar for diafol
0
83
Member Avatar for Martin C++

I m not sure if thats right section, but I m pretty sure it's done with PHP. So the question is, how can I change a conetent inside a division without navigation to new page. For instance I have 4 division. Header, links, content, footer. Now if i click some …

Member Avatar for diafol
0
1K
Member Avatar for tobeeornot

Hi, New to wordpress and php so please bear with me. I am using WAMP as a testing server and Dreamweaver CS5 as a text-editor to manipulate the theme files. I have successfully set up a live local connection between WAMP, WP and DW and can view the live index.php …

Member Avatar for tobeeornot
0
477
Member Avatar for SarenaWilliam

Hi ! I would Like to Know that which framework is the best for PHP development . I already use code ignator but it not much comfortable kindly suggest me the best frame work.?

Member Avatar for cereal
0
71
Member Avatar for Martin C++

Probably a stupid question but why does the following loop works ? There is nothing wrong with it I just want to understand how does this code know how many entries I have in database. [CODE=PHP] $result = mysql_query("SELECT * FROM post_categories"); while ($row = mysql_fetch_array($result)){ echo $row['Name']; } [/CODE] …

Member Avatar for cereal
0
2K
Member Avatar for cmps

Hello, I want to display all data from database (repeat) and not only the last one: In classic php I do this using: [CODE]... $row_record = mysql_fetch_assoc($record); do { echo 'Record <br />'; }while($row_record = mysql_fetch_assoc($record))[/CODE] In advanced php (using class) I decided to create my own way, so here …

Member Avatar for cmps
0
180
Member Avatar for jaycastr

I have save formulas and variables in a database and when I retrieve them I want php to calculate the value like so [CODE] $x = .0832; $y = .0673; $z = 1.5; $formula = '$x -(($x-$y)*($z-1.0))'; $newformula = str_replace('$x', $x, $formula); $newformula = str_replace('$y', $y, $newformula); $newformula = str_replace('$z', …

Member Avatar for diafol
0
998
Member Avatar for trektrak

Hello, Is it possible to get data from another web server (not local webserver) using php and by that I can create the php connection to store into local mysql ... ? Any ideas?

Member Avatar for trektrak
0
75
Member Avatar for aadebayo

Hello I have managed to get the pdf working. There is a problem though, I need 2 records to be displayed on every row, instead of just one. In getting 2 records to display, I created a table with a row and 2 columns, then using a counter variable to …

0
76
Member Avatar for lordx78

auth.php [code=php] <?php // start session session_start(); // convert username and password from _POST or _SESSION if($_POST){ $_SESSION['username']=$_POST['username']; $_SESSION['password']=$_POST['password']; } // query for a user/pass match $result = mysql_query("SELECT * FROM users WHERE username='" . $_SESSION['username'] . "' and password='" . $_SESSION['password'] . "'"); // retrieve number of rows resulted …

Member Avatar for markashworth
0
4K
Member Avatar for rimilbadal

i have a page that has a textarea (id="elm1") i post this value to the same page when a submit page is clicked to send the value of the textarea in a html mail the textarea will contain html code but when i use it only the text comes in …

Member Avatar for rimilbadal
0
928
Member Avatar for rse

Hello, I managed starting a session and store some data when a user login to the system. The user can edit his/her prifile by clicking on edit, then some of the data will show in the edit form. Now I have the form with empty fields and I need to …

Member Avatar for rse
0
138
Member Avatar for jaycastr

Hey Guys, My problem is that i want to get a random number given a specific range. But it the range is a small decimal or float it rounds up. Here is what i have so far [CODE] $xl=$row['x_lower']; $xu=$row['x_upper']; if(isset($xl) && isset($xu)) { $x = rand($xl,$xu); echo $x; } …

Member Avatar for diafol
0
106
Member Avatar for DarkWolffe

I have an [URL="http://pantheonarts.host22.com/xml/feed.xml"]RSS feed[/URL] set up using XML on the website I've developed for [URL="http://pantheonarts.host22.com/"]Pantheon Arts Unlimited[/URL]. I'm still fairly new to PHP and MySQL, so I find myself often jumping to various forums looking for answers for what are usually fairly obvious questions. My newest problem, however, I've …

Member Avatar for DarkWolffe
0
189
Member Avatar for aadebayo

Hello I have got a code below that works perfectly in generating html via PHP. However, I will like to export the results into PDF or Micorsoft word, but I am struggling. Please can anybody point me in the right direction [CODE]// Get house group details for this member //$memberRecord …

Member Avatar for aadebayo
0
119
Member Avatar for stanley87

May i know how to matching 2 array keywords? e.g I have 1st array keyword like kfc,mcd,fastfood,etc 2st array keyword like kfc,mcd If i want to get the matching keywords among these 2 arrays, how to i write the matching code? Thank advance for your help.

Member Avatar for stanley87
0
185
Member Avatar for DarkBerzerk

I need Video Gallery With cPanel, i searched all over the World Wide Web and found nothing xD doesnt matter free or for money, im ready to pay for it, Video Gallery With cPanel to upload and edit and those things. :/

Member Avatar for diafol
0
109
Member Avatar for twitah

[CODE]<?php include('header.php'); foreach($_POST as $key => $value) { $protectie[$key] = filter($value); }if(isset($_POST['submit']) && $_POST['type'] == "facebook") { $num1 = mysql_query("SELECT * FROM `facebook` WHERE `facebook`='{$protectie['url']}'"); $num = mysql_num_rows($num1); if($num > 0){ $mesaj = "<div class=\"msg\"><div class=\"error\">Facebook Pages has been added before!</div></div>"; }else{ mysql_query("INSERT INTO `facebook` (user, facebook, title, points, cpc) …

Member Avatar for diafol
0
152
Member Avatar for bibiki

Hey there, I am trying to build a small survey for a homework assignment. So, I have the following code: [CODE] $con = mysql_connect("localhost","user", "mypassword"); if (!$con) { die('Could not connect: ' . mysql_error()); } mysql_select_db("mydatabase", $con); $slq = "INSERT INTO results VALUES('', '', '', '', '', '', '', '', …

Member Avatar for bibiki
0
150
Member Avatar for waveydaveywaves

I have literally been banging my head on my keyboard out of frustration. I'm trying to display PHP sessions as values in my php form, but it's not going so well. here's what I have: [CODE]<?php session_start();?><html> <head> <title>Create An Event</title> <style> label {float: left; width: 100px;} input[type=text],textarea {width: 210px;} …

Member Avatar for diafol
0
224

The End.