39,320 Topics
| |
SO i WAS TESTING my code..and it doesnt seem to work...here it is <?php require_once('../includes/config.php'); if ($_Session['roleID']=1) { echo "admin"; } elseif ($_Session['roleID']=2) { echo "faculty"; } ?> | |
hello masters, I have a problem regarding limiting the pages a certain user can access..in my case, i have added a roleID to my members table... here is the original code first <h1>Welcome SICS Admin!</h1> <ul id='adminmenu'> <li><a href='index.php'>Modify News Archive</a></li> <li><a href='categories.php'>Categories</a></li> <li><a href='users.php'>Faculty</a></li> <li><a href="../" target="_blank">Department Website</a></li> <li><a … | |
Want to count ads clicks and Impressions using wordpress plugin. how to do this .. send me the links regarding this.. Clicks and impressions have to store in other domain database. | |
| **i have some code to redirect a user to a page if their login details are correct. part of the code is as below but it never redirects to the specified page. help me sort this out** if($pass==$dbpass){ //safely redirect user to the home page and start a new session … |
Here is the scenario... I have a website that orignated as an MLM / retail combination site... It was determined that we needed some seperation between the Rep portion and the Retail portion, so I spent weeks modifying the code in over 40 scripts to separate a visitors path basedn … | |
Guys, I know its easy to do it, but I'm having a hard time doing it. Please help me, I want to get the checked items in checkbox. The problem is that it gets the last value of it. I just used echo to get all the values, but how … | |
Hello Guys, I have a Question, it possible storing image to dabase using blob in the Framework of CI? This is my Code in Controler. function get_data_from_post(){ $data['page_headline'] = $this->input->post('page_headline',TRUE); $data['page_title'] = $this->input->post('page_title',TRUE); $data['keywords'] = $this->input->post('keywords',TRUE); $data['description'] = $this->input->post('description',TRUE); $data['page_content'] = $this->input->post('page_content',TRUE); $imageName = $_FILES['featured_img']['name']; $data['featured_img'] = $this->input->post(file_get_contents($_FILES['featured_img']['name']),TRUE); return $data; … | |
Eariler I wrote this topic: http://www.daniweb.com/web-development/php/threads/482142/searching-using-optional-parameters and I got ideas and got to this point with help of another guy: <?php $whereClause = "WHERE "; foreach($_POST as $k => $v ){ if( $v != "" ){ $whereClause = $whereClause . $k . "='" . $v . "' AND "; } … | |
I have this code which ironically WORKS on another page i have but for some reason will not work with my new page even though LITERALLY its the exact same function and should work regardless but with my luck it wont so i need help, maybe i have a small … | |
So. I've been trying to use switches from PHP. I've done this many many times. I end up cursing up entire world and threatening everybody in the world, I was sitting here for about an hour screaming the worst curses there possibly exist. I don't know what happened. I don't … | |
How to Send an Email with a File Attachment in PHP? | |
| |
Hello, I wonder why this condition does not work: registration3.php <?php include('includes/koneksi.php'); $email = isset($_POST['email']) ? $_POST['email'] : ''; $confirmation = isset($_POST['confirmation']) ? $_POST['confirmation'] : ''; $password = isset($_POST['password']) ? $_POST['password'] : ''; $fname = isset($_POST['fname']) ? $_POST['fname'] : ''; $lname = isset($_POST['lname']) ? $_POST['lname'] : ''; $gender = isset($_POST['gender']) … | |
Hi all, i would like to ask about, i have (date_from) and (date_to), and i want the range of the date show in the checkbox. Example: date from: 6/8/2014 and date to: 8/8/2014. it will show 6/8/2014, 7/8/2014 and 8/8/2014 along with check box. so, i have success make the … | |
Hello guys I really need your help. I Had created attendance system but I stucked up with time in button. I have created a time out and time in button and both are working fine and great but the main problem is that I am unsuccessful for making the time … | |
How to share sigle post when click on button ex. fbshare, twitshare and show them in facebook. Do you know some examples or tutorial? | |
Good Day, There's a sticky that TUT about uploading image but i want the restrictions to be in this manner. But my problem here is no notice, no errors but the image file won't upload eventhough the other data has been updated, Here, check my codes. this quite long to … | |
Well, it has recently been bugging me that I have 8 years of working with PHP under my belt and not once have I tried to implement a custom solution to integrate PayPal into any of my ecommerce projects. I've worked with a lot of PCI API's from different providers … | |
Want to show div on front end wordpress website with wordpress plugin.. If User activate the plugin then div should show on the front side of the wordpress .how to add ? Used add_filter('thecontent') and some more. nothing is working . | |
Hello, I am creating an elearning that tries to record date and time and I am looking for an automated system to do that so that the user won't enter any other information: As far as now, I only uses Date Time [ input textbox ] Is there other way … | |
<?php session_start(); ?> error_reporting(E_PARSE); include "connection.php"; $User_ID=$_SESSION['UserId']; $query = mysql_query("SELECT * FROM Users WHERE UserID='$User_ID'"); $row = mysql_fetch_array($query); $filename=$row['PicUrl']; $username=$row['UserName']; $fName=$row['FirstName']; if(isset($_SESSION["UserName"])){ if(!empty($filename)){echo '<img src="'.$filename.'" align="left"width="150px" height="100px"/>';} echo $fName; echo"<li><a href='logout.php'>Click here to Logout.</a></li>"; echo"<li><a href='user_update.php'>edit your account detail</li>"; } if(empty($_SESSION['UserName'])){ echo"<li><a href='login.php'>login</a></li>"; echo"<li><a href='register.php'>Sign Up</li>"; } ?> </li> </ul> … | |
Hi, I make a delete page with php to delete clients from clients table. With this page I try to delete images from gallery table. for example I wish to delete client ABC from clients table and it have three images in gallery table. here under I paste the code … | |
I have got some piece of code to send multiple attachments through mail function in php. The mail with attachment will be sent if there is only one attachment. But mail sending fails if add two or more files in the array. This is my code // array with filenames … | |
Hi All , am geting this error Parse error: syntax error, unexpected ';' in /home/a2856241/public_html/plus1.php on line 10 whith this code, <?php $con=mysqli_connect("host1","djslim","opensaysme","missionbase1"); // Check connection if (mysqli_connect_errno()) { echo "Failed to connect to MySQL: " . mysqli_connect_error(); } mysqli_query($con,"UPDATE table1 SET score=score+1 WHERE id=['$id'])"; mysqli_close($con); header('Location: ./LaunchControl.php'); exit; ?> … | |
Hello, I wonder why I get this error: Parse error: syntax error, unexpected '&&' (T_BOOLEAN_AND), expecting ')' in C:\xampp\htdocs\squprime\registration1.php on line 65 line 65: if(!empty($stu_fname && $stu_lname && $stu_email && $stu_telp && $stu_skype)){ Thanks before. | |
Hi, I'm trying to check the format of the string with `preg_match()`. It has to accept only the `(zero or more of ,.* )(exactly 9 or 5 digit number)(1 or more of ,.* )(postive integer <= 4digits)(zero or more of ,.* )` format of strings. Here, is what I tried: … | |
dear i lost my website cpanel password can any one help me but iam using webemail it is possible to recover through this? | |
class phpParser{ public $pageString; //some other properties and methods class software{ private $baseName; private $url; private $html; public initiateValues (){ $this->html = new phpParser (); } } // Now how to access properties and methods of phpParser class through software class member $html (which is actually object // of phpParser … | |
I want to insert a URL inside an echoed table row. Here is the URL and table column: <a href="modify-user.php?id=<?php echo $row["id"]; ?>">Modify</a> Here is the table column: printf("<td class=\"listusers\">" "</td>"); Thanks for your help in advance. | |
Hi Friends, I am using this code to upload image but it seems my call is not getting inside function. I put some echo commands for debugging. all I get output is after selecting file "hello entering function". but do not get other echo command print. Neither insert command is … |
The End.