39,320 Topics

Member Avatar for
Member Avatar for youvi

Hello,Can anybody show the work flow (working) of MVC architecture with example??Provide me the code...if you can..

0
69
Member Avatar for gwhite12

I have this code. I put everything within <?php ?>. Because I thought that would help. I have the code commented for easier read. Can someone please show me where I went wrong, or what I forgot? [code] <?php ?> <html> <head> <style> body { background-color:#000000; color:#E27907; font-family:Verdana,Arial; font-size:10pt; letter-spacing:2; …

Member Avatar for Nahiyan
0
5K
Member Avatar for manzoor.ilahi77

[CODE]<table width="100%" align="center" border="0" bgcolor="#FFFFFF"> <tr height="30px" style="color:#000000;" > <th>Unique ID</th> <th>Username</th> <th>Form Name</th> <th>Name</th> <th>Mobile</th> <th>DOB</th> <th>&nbsp;</th> </tr> <? /*$username="username"; $password="password"; $database="your_database";*/ mysql_connect('locahost', 'username', 'password') or die(mysql_error()); mysql_select_db('database') or die(mysql_error()); $query="SELECT * FROM table_name WHERE user_id='username'"; $result=mysql_query($query); $num=mysql_num_rows($result); mysql_close(); $i=0; while ($i < $num) { $form_id=mysql_result($result,$i,"form_id"); $form_name=mysql_result($result,$i,"form_name"); $username=mysql_result($result,$i,"user_id"); $first=mysql_result($result,$i,"first"); …

Member Avatar for rpv_sen
0
181
Member Avatar for ychan623

Hello, I'm new to php, I'm working on a website for employment. I want user to be able to pull data from mysql by using selection from drop down menu. I have a table call jobs, inside this table there are 5 columns: JobType, Place, Wage, Phone, Date. I created …

Member Avatar for Awon02
0
2K
Member Avatar for MasterGberry

In a few URLs I have on my website, they feed a parameter into the URL that sometimes contains [] in it. I have a preg_replace fixing some links, but the [] breaks my current system. How can i make this work? (I need it in the second half, for …

Member Avatar for pritaeas
0
175
Member Avatar for Buppy

Hi, I have a code here (in a model behavior). [CODE] function beforeFind(&$model, $queryData) { foreach($model->cryptedFields AS $key => $field) { if(strstr($queryData['fields'],$field)) { $queryData['fields'] = str_replace($field,DboSource::expression("AES_DECRYPT({$value}, '{$this->aesKey}')"),$queryData['fields']); } } return $queryData; } [/CODE] I want certain fields to be affected with AES_DECRYPT, however, it does not work. When i use …

0
58
Member Avatar for felix001

Is there an easy way to post a form to the same page. I currently have an HTML (/javascript) page with a number of selection forms. I want to then display certin HTML below below based upon the users selection. Many Thanks,

Member Avatar for broj1
0
74
Member Avatar for jacksantho

Hi, I needs to create a PDF report for my project. Did PHPExcel suits for creating a PDF document. I needs a tutorial to create a PDF document. Please help me out.

Member Avatar for broj1
0
54
Member Avatar for Ichcha

the following code gives first date of week for the given date range. how to get week number from the date??? thanks. [CODE]<?php $start = $week = strtotime('2011-01-01'); $end = strtotime('2011-02-01'); while($week < $end) { echo date('Y-m-d',$week), PHP_EOL; //echo week num??? $week = strtotime("+1 week", $week); } ?>[/CODE]

Member Avatar for Ichcha
0
103
Member Avatar for mwenyenia07

i have written an application(login page) using codeigniter 2.02. when i try to load the page, it displays the following message: Fatal error: Class 'Controller' not found in /var/www/Files_Manager/application/controllers/login.php on line 2 this is the script: [CODE]<?php class Login extends Controller { //constructor function login() { parent::Controller(); $this->load->helper('url'); $this->load->helper('form'); $this->load->library('form_validation'); …

Member Avatar for aquilax
0
128
Member Avatar for Jaklins

This is a very newbie post. I think I'm just missing something. Anyway. I'm trying to display the contents of one column's field (not column name) specified by the contents of another filed in the same row. Here I show you my table and what I need: [code] Enter password: …

Member Avatar for Jaklins
0
201
Member Avatar for megachip04

this is the code to email confirm. The user clicks on the link in the email, passing the code through url to this page. Then the data is transferred from a tmp table to main one. I have queried in phpmyadmin and it works fine. But when i actually use …

Member Avatar for rv1990
0
189
Member Avatar for gregous

Hi I have the error message in the line 61 : mail($mailto, $subject, $message, $header); I can't figure out what is wrong :( Can you advise ? thanks [CODE] <?php /* * v1.7 * * * */ $fromname = $_POST['fromname']; $mailfrom = $_POST['mailfrom']; $msg = filter_var($_POST['msg'], FILTER_SANITIZE_SPECIAL_CHARS); // filter from …

Member Avatar for Zagga
0
344
Member Avatar for Farhad.idrees

Hi i have 2 files one is Left.php which is is getting categories of product...code is [CODE] <?php require('Connection.php'); $query ="select distinct(P_Category) from tblProducts_info"; $result = mysql_query($query); if(!$result) { die('echo invalid query:,mysql_error()'); } else { if(mysql_num_rows($result)>0) { while($rows= mysql_fetch_array($result)) { $P_Category = $rows['P_Category']; $cat_List=""; $cat_List = "<li class=\"odd\"><a href=\"services.html\"?P_Category=$P_Category>$P_Category</a></li> "; …

Member Avatar for MagicMedia
0
157
Member Avatar for quibbie

I am looking at building a website that will allow people to sign up and post stats every week about others. For example, Joe has a show dog and likes to compete so Joe comes to to the site and posts. Dog Name: Breed: Weight: Skills: Week 1: Fastest lap …

Member Avatar for MagicMedia
0
163
Member Avatar for tsp003

I have the following code to bulk upload to several different tables [CODE]<?php /* Script to bulk import users into a Joomla installation (v 1.5). */ // Hande form upload if(isset($_POST['import'])) { $mysql_host = trim($_POST['mysql_host']); $mysql_user = trim($_POST['mysql_username']); $mysql_password = trim($_POST['mysql_password']); $mysql_schema = trim($_POST['mysql_schema']); $table_prefix = trim($_POST['table_prefix']); if(!mysql_connect($mysql_host, $mysql_user, $mysql_password) …

0
85
Member Avatar for heshanm

Hi, In my system,when i submit my form there is a message comes as "A new account number 1 is created successfully. Thereafter when i try to click on the "refresh" button another new account number is automatically created. Can anyone give some piece of code to avoid that problem? …

Member Avatar for heshanm
0
159
Member Avatar for hardinguse

I am receiving the following error: Notice: Undefined offset: 1 in /home/content/53/7382753/html/Summer/wootsummer.php on line 68 Error, insert query failed on my code that is live at [url]http://obsidianpunch.com/Summer[/url] The offending line is [code]$topnow=$top[$countforme];[/code] however $top and $countforme are defined, so I am not sure why this is causing an error. Any …

Member Avatar for hardinguse
0
839
Member Avatar for spixy

I am playing a web-based game and i want to know if Php is capable of doing this problem this are the conditions: 1. there will be 3 text-areas a. the 1st will contain the guild's members b. the 2nd will contain the enemies c. the 3rd will contain the …

0
98
Member Avatar for spixy

My professor gave us a sem-long project, before he introduce us php.. so here it goes create a dynamic website with the following situation 1. there will be an existing database, the database contains the following a. student name b. student id no. c. address d. other personal info 2. …

Member Avatar for spixy
0
226
Member Avatar for karthik_ppts
Member Avatar for IIM
0
123
Member Avatar for mgt

Okay, here's the scenario. The same user accesses the same form a second time in order to place a new order. Both the new order and the old order are stored in a MYSQL table (called "orders"). My thought is that, when the new order is placed, I need to …

Member Avatar for mgt
0
120
Member Avatar for jacksantho

Hi, How to avoid the data insertion in mysql tables by refreshing the page using php. I am not redirecting my page. I am using $_SERVER['PHP_SELF'] in form action. Please help me out. its very urgent

Member Avatar for sDJh
0
72
Member Avatar for divyakrishnan

Hi... I want to find out whether a file is existing or not The file is stored on another machine in the same network . I tried the following code.But always showing "The file is not existing". [CODE] <?php $filename = 'file://192.168.0.15/E:/PDF/p.pdf'; if (file_exists($filename)) { echo "The file $filename exists"; …

Member Avatar for sDJh
0
99
Member Avatar for klemme

I have this bit which I have actually only tried in Google Chrome, but it works finte there: Im using ajax to get data from the Db, when popuating one select list based on whats selected from another: But in Internet Explorer 9, it doesnt work: [CODE] // JavaScript Document …

Member Avatar for blocblue
0
197
Member Avatar for masterjiraya

the code in php: name it as postback.php [CODE=PHP] <?php $q=$_GET['q']; $query_type=$_GET['query_type']; $words=explode(' ',$q); $con = mysql_connect('localhost', 'root', '')or die('Could not connect: ' . mysql_error()); mysql_select_db("clc_books", $con)or die('cannot connect'); $q = preg_replace('/\s\s+/', ' ', $q); // remove extra space echo "<table border='1'>"; echo" <tr> <th>book id</th> <th>book number</th> <th>book name</th> …

0
91
Member Avatar for vectro

I am using Joomla with the Ambra Subscriptions module to accept payments. When a new customer signs up and makes a payment, their account is not being automatically activated. I find myself having to activate every account manually after a new customer complains that they can't log in. Under 'Site …

Member Avatar for vectro
0
232
Member Avatar for titusnainggolan

Hi, I want to make my website in two language. I need to make library for both of language. And I get template of those library with extension .mo. And those library are included in file .php. I want to make a new library but I can't open and create …

Member Avatar for pritaeas
0
123
Member Avatar for kadriirdak

Hi There, I have an XML file and I list them by check boxes, categorized by their parent (branch). After selection of the check box, I take them and give the values `$branch`(only one at a time) and `$roles`(can be many eg. SBP|BNA) to web services. And run this web …

Member Avatar for kadriirdak
0
83
Member Avatar for feedz87

- I have the problem where my update is not not working.Anybody can help me... FORM <code> <?php session_start(); include ("../entity/login_class.php"); include ("../entity/admin_class.php"); include ("../entity/customer_class.php"); $Customers = new Customer(); $id = $Customers-> getCargoID(); $Customers ->getCargo($_GET['id']); $id = $Customers->getCargoID(); $cargoCode = $Customers->getCargoCode(); $cargoDesc = $Customers->getCargoDesc(); ?> <form method="post" name="updateCustomer" id="updateCustomer" action="../controller/customer_control.php" …

0
57

The End.