39,326 Topics
| |
[CODE] <?php session_start(); // makes an array $colors=array('red', 'yellow', 'blue'); // adds it to our session $_SESSION['color']=$colors; $_SESSION['size']='small'; $_SESSION['shape']='round'; $_SESSION['diameter']='10cm'; $_SESSION['LoggedIn']='user'; print "Done"; function fnCheckSession(){ if ($_Session['LoggedIn'] !=null) echo "Session variable exist."; else echo "Session variable does not exist."; } fnCheckSession(); ?> [/CODE] The following errors appears: Done Notice: Undefined … | |
Hi there.. I'm quite a noob in PHP.. I'm working with Joomla at the moment.. and I'm supposed to check whether or not the fields in the user registration form are filled with the correct format.. For example, the user name should have this sort of format NNN-NNN-NNN.. How do … | |
Hello Everyone, Thanks for taking your time to look at my post. I am having a problem with my PHP file which is giving me the following error whenever a header("Location: ") is used and the set_cookie function: Warning: Cannot modify header information and it always says the output was … | |
hello there, i'm having a bit of trouble about this. im making a regiter page for our project and im using PHP, and im having a little problem, it says that: Could not execute the insert query.. but i got all my fields right?.. [ICODE]<?php include("config.php"); if(isset($_POST['submit'])) { $fname = … | |
Hi Guys, I would like to ask help on how to create a page using php. The page consist of a multiple choice quiz wherein the choices are in radio button. It has a fixed time of 15 minutes to answer the questionnaire. The page has two users the student … | |
[CODE] <?php //LOAD USER $result = mysql_query("SELECT * FROM event"); while ($data = mysql_fetch_array($result)){ ?> <tr> <td><?php echo $data['event'];?></td> <td><?php echo $data['tempat'];?></td> <td><?php echo readDate($data['mulai']);?></td> <td><?php echo readDate($data['selesai']);?></td> [/CODE]> I have this error: Warning: mysql_fetch_array() expects parameter 1 to be resource, boolean given in C:\xampp\htdocs\php_template2\event_manager.php on line 206 Line 206 … | |
Hello, I am trying to redirect “http” to “https”. I successfully followed the steps to create SSL Certificate as per this website: [url]http://robsnotebook.com/xampp-ssl-encrypt-passwords[/url] However, it seems that it didn’t work. I am still getting the following error messages: For IE browser: There is a problem with this website's security certificate. … | |
[CODE] session_start(); // undefined index: login if (!isset($_SESSION['login'])){ echo "Anda tidak berhak mengakses halaman ini."; exit(); } //Fungsi baca data dari database [/CODE] Hi, Whenever I press eventmanager, the following error appears: "Anda tidak berhak mengakses halaman ini." What codes should I write so that I could pass the echo? … | |
Hi! I've been reading this for hours and I can't find the error. Obviously I'm brand new at reading codes so can anyone help me? I think the error is in the following line (under logo config). Thank you so much! // logo config ----------------------------------------------------// [CODE]function simple_logo(){ $src = (get_option('Simple') … | |
Hello, Despite much searching, I've hit a wall with trying to get a varying number of records inserted into a database. Here's what I'm trying to do..... I'm building an online sign on site for races at a sailing club. For the sign on page, I want to make it … | |
fine_per day=1 from book_due date and returned_date as number of days in which fine is added to get the fine............ how this can b done in php.what is the formula for calculating the fine | |
I am using a sms site's api to provide free sms to my site's visitors, as this site has provided me http api and based on that i developed these 2 following pages. freesms.html [CODE]<html> <head><title>Send Free Sms</title> <script language="Javascript"> function validate() { var valid = true; if (document.formvalidate.FieldData1.value == … | |
I'm using [URL="http://colorpowered.com/colorbox/"]colorBox[/URL] to show up a dynamically populated Image. I need to show one image as the Thumbnail & when this thumbnail is clicked a lightbox opens and a group of images slide inside it.. ColorBox uses rel tag to group the images that are displayed, I need to … | |
I have a set of 4 HTML list items and I'd like to shuffle the order they appear in once a week. I have found the following which could be used - but at the moment, it only returns one list item - how could I modify it to show … | |
My doubts are: when the code of functions.php (wordpress) will be executed? can I declare there global variables to use them in other functions? I'm trying to understand the code of a function which initialize some parameters and start with this code: [CODE]if ( $_GET['page'] == basename(__FILE__) ) { ...}[/CODE] … | |
Hello Everyone I have a simple form posting to mysql database. I set one of the fields to be Text Area. I have and HTML Link Code that needs to be in that field. When I upload he data to the db, my " gets hashed out a \ gets … | |
I have one server with zend application and for that application I want to create CMS (using drupal). So problem is how can I put both drupal & zend source. [url]www.domainname.com[/url] (which working into zend framework). Now I want to create CMS for this [url]www.domainname.com[/url] & zend application run which … | |
What is the best book to learn ,PHP,Javascript,DHTML, and AJAX? | |
hi, i need to subtract one date form the other and take the difference in minutes or seconds.. i'm getting the first date from the data base in 'Y-m-d H:i:s' format and second date is the current date (same format). and i want to know the difference between them in … | |
I wanna create subdomains dynamically than manually I've got this script but can't make it work...I've got my website hosted on a server..Can anybody tell me that is it [B]possible[/B] to achieve that... [CODE]<?php ############################################################### # cPanel Subdomains Creator 1.1 ############################################################### # Visit [url]http://www.zubrag.com/scripts/[/url] for updates ############################################################### # # Can … | |
I am fairly new in this world and I still have a lot to learn. I am making a dynamic page where I have to load 7 images for the database and I'm not even getting if anyone can help me. thanks <?php require_once('../Connections/ligacao.php'); ?> <?php if (!function_exists("GetSQLValueString")) { function … | |
Alright, I have a members area, area.php, and I used mysql to find the userlevel and display content depending on the userlevel, 1 for user, 2 for admin. I made it, but it displays both the user and admin for 1, and 2. [CODE]<?php // Members Area // session_start(); $usernamee … | |
Hi, I am uploading multiple file acc. to the limit enter in the textbox. Suppose in a text box if i enter 2,then two browse button can upload two different file having different format 1st file=only jpg 2nd file=only text file I completed all the validation part of both file.what … | |
Hello, I have a code that only add an image in my database and I want to add more, but only one form. Can anyone give me some ideas how to do this? thanks | |
I created a program using php that will attach a file if you click "attach" button. the problem is that i always receive this message when i try to attach a file even though I didn't create an error message that states this "attachment failed. this may be due to … | |
I have the following codes: [CODE] <?php // a) function fnTripple($a) { $a = $a * $a; return 3; } echo fnTripple(4); // b) $a = 5; $b = 5; // c) $b = $b + $a; // d) $d = $d + $b; $e = $e + $b; // … | |
Hi. I'm looking for a script (in either JavaScript, PHP or both) where you enter the amount of servings you want for a recipe, and it'll calculate the recipe. I can't find a script anywhere! Can anyone help me? To see an example, go to [URL="http://tastykitchen.com/recipes/breads/plain-bagels/"]http://tastykitchen.com/recipes/breads/plain-bagels/[/URL] Thanks! | |
Hi. I'm trying to multiply fractions. How can I take '1 1/2' and multiply it to get 3? (is there some special format like '1-1/2' that I need to use to multiply it?) Thanks | |
Hello, I'm trying to display a table in PHP that uses multiple MySQL tables with some repeated field names. [U]Master table field names:[/U] Name, Student Major, Course Major, Course #, Credits, Course Name This is what I have so far...but the variables in the loop are not working and I'm … |
The End.