I have a website with an include script that will have a various number of variables.
Here are some of the types of URLs and variables:
Main page: index.php
Login page: login.php (redirects to index.php after login).
Logout page: logout.php (redirects to login after logout).
Profile page: index.php?id=profile
Users password page: index...
I'm currently building an affiliate program (a bit like CJ) with Paypal checkout. When people sign up as an affiliate (=to sell their own products from their own website) they receive 2 php lines that they have to insert into their shop.
In the header:
<?php include 'http://www.mydomain.com/tracker/tracker.php?xyz='.$_GET[xyz]; ?>
In...
Hello all
i have application that generate php/html/asp web sites and i like to be able to
let the possibility to test the sites from within the application . is there any possibility to do that ?
...
I have a function isNotEmpty which returns true if the string is not empty and false if the string is empty. I've found out that it is not working if I pass an empty string through it.
function isNotEmpty($input)
{
$strTemp = $input;
$strTemp = trim($strTemp);
if(strTemp != '') //Also tried this "if(strlen($strTemp) > 0)"...
Hi -
I'm writing some php code, and I'm frequently accessing my MySQL database to read and update fields.
My current code includes a class called dbconnnect, and I use it as follows:
class edit_data extends dbconnect {
//<some php code>
parent::connect();
//<get info from database>
parent::disconnect();
//<evaluate data>
My questio...
I am using Kohana but this question applies to Rails, CI, or any other MVC web development framework. Where is the best place to stick one's server side AJAX scripts?
I was planning on creating an Ajax_Controller and using a method/action per individual script.
For example, a login form on the home page index.php/home would send an XM...
my symfony sandbox is inside the htdocs of my xampp folder which is inside the program files in c drive
i.e.
c:\program files\xammp\htdocs\sf_sandbox\
but when i try to run the command symfony -v it gives the error
'php.exe' is not recognized as an internal or external command
can somebody help me? what am i doing wrong?...
...
Here's my situation: I'm an ASP.NET Developer first and foremost. That's not going to change anytime soon. I have built my small business on it. With that being said, I'm looking to add other technologies to my arsenal. Not just for learning purposes, but to one day be able to offer clients an alternative solution. For this reason, ...
I'm using CakePHP to produce a Facebook application (though the problem is not Facebook specific). As usual, I'm struggling to get the reverse routing to work properly. Previously I've abandoned the routing functionality, but this time I'd really like to make it work.
The problem is basically that Cake produces URLs relative to the base...
What's the difference between
$PDOStatement->fetchColumn();
and
$PDOStatement->fetch(PDO::FETCH_COLUMN);
(if one exists)? Or are they functionally similar but only aesthetically different?
...
In PHP I would do it like this:
session_name("special_session_name");
So how do I do it with Cherrypy?
Just need to find exact equivalent for it.
PHP manual page:
http://fi2.php.net/session_name
...
Hey,
I'm creating a browser based game and at the moment I'm designing the script that updates the position of my character when he/she clicks on a different part of the map.
I am using a bit of ajax to do this which send a request to a php file called position_update.php. But for it to work I need to send two values along with it so i...
hey,
Below is my script that updates my characters position in my database:
<script language="javascript" type="text/javascript">
function positionUpdate(){
var word = document.getElementById('test').value;
var queryString = "?word=" + word;
ajaxRequest.open("GET", "new_position.php" + queryString, true);
ajaxRequest.send(null);
alert(...
In the past, I've always edited all my sites live; wasn't too concerned about my 2 visitors seeing an error message.
However, there may come a day when I get more than 2 visitors. What would be the best approach to testing my changes and then making all the changes go live simultaneously?
Should I copy and paste ever single file into a...
I have quite a long data mining script, and in parts of it I echo some information to the page (during a foreach loop, actually.)
However I am noticing that the information is being sent to the browse not immediately as I had hoped, but in 'segments'.
Is there some function I can use after my echo to send all the data to the browser im...
I'm doing a print_r on a array stored on a session variable and for some unknown reason it's adding a number after the array prints.
Example:
Array
(
[0] => 868
[userid] => 868
)
1
If I do a print_r directly in the function itself and before the variable gets stored on session variable, it doesn't add that number 1.
Solution...
As title mentioned, how to create a status bar(like facebook or twitter). User can type in what is he doing now? I believe its using AJAX, but then how to store to database? (I am new to AJAX)
For example:
User type in "I am eating now", then click the "update" button, then It will update automatically to the status field, displaying th...
I am going to be writing a PHP mailing list system. Ideally, I would like for the templates styles to be easy to manage. In my current system, I have the styles all hardcoded in the template like this:
<a href="http://blah/blah/blah" style="color: #a8a8a8;">click here</a>
This works alright until the person managing the template decid...
I am creating a dynamic form where the user will have the ability to add a set of inputs to the form. The html looks like this:
<form>
<input id="title1" class="title" name="title1" type="text" value="">
<input id="productionCompany1" name="productionCompany1" type="text" value="">
<input id="year1" name="year1" type="text"...
I need to send out an email with multiple image attachments from PHP. I currently have a test set up that uses two hard coded images. I compile the email with al the necessary headers and send it out. However, when I receive it, it only shows the first image as an attachment. The second image seems to be ignored (tested with both Groupwi...