i am beginner of shopping cart application. i am installed os commerce downloaded code in my local computer. It is up some extent working, but before checking page i stuck on same page.
i am trying to pass variable information to javascript function, it is working. And i required to set java script variable set to session. how can ?
i...
My apologies up front for being a) a newbie and b) almost certainly not giving enough info.
So I have app that uses ZF to fetch data from MySQL and display it to the user.
The user can select a row of data and fetch additional information (username, hostname, etc...).
I'm having an issue with PHP puking when ZF returns null data from ...
Hello,
Im a new Drupal user . I want to be able to handle payments on my Drupal website. I would like to know which would be a better option, LM_Paypal module or the Ubercart module ?.
Does the Ubercart module have any specific advantages over the LM_Paypal module or vice versa ?
Please help.
Thank You
...
The url shortening service I'm building needs to display some basic click stats to users: # of clicks, conversions, referring domains, and country (filterable by a date range). I'll possibly want more advanced stats in the future.
Is there existing open source software that will allow me to pass events to it and then easily display a ba...
Hi,
I am trying to extend the Upload library in CodeIgniter. I have been trying all morning, following various tuts and forum posts, but can't get it to work.
If I add the function I want directly into the Upload.php library, it works-- but I know this isn't the right way, and want to do it right since I'm doing it.
Here is the conte...
I'm looking for a way to find/replace links to images (within user-generated content) without touching links to non-images.
For example, the following text:
<a href="http://domain.com/arbitrary-file.jpg">Text</a>
<a href="http://domain.com/arbitrary-file.jpeg">Text</a>
<a href="http://domain.com/arbitrary-path/arbitra...
So, I have a .pdf file and I need to be able to determine if it was created by being scanned into a PDF or not. I'm trying to determine if it is a pdf I can display as text or not.
I have PHP & Zend at my disposal.
I'm thinking I might be able to use Zend's
$pdf->properties['Producer']
but I'm not 100% sure.
Is there any way to be...
I need a fix for this.here is just part of my code
<?php
$number = 30;
while($number > 0) {
$number--;
sleep(30);
print "$number . Posted<br>";
}
?>
The loop process in the loop is actually much bigger, i just put the important stuff.
Anyways as you can see it should print
30 posted
(wait 30 seconds)
29 Posted
(wait 30 seconds...
I have a form that submits a search for blogs on my site via GET.
The form works fine, but when submitted, the url on the following page reads ("Find it" is the value of my submit button):
www.example.com/search.php?sub_q=Find+it%21&q=tennis
This just isn't an aesthetically pleasing url. Is there a simple way to exclude the submit...
How can I sort an array based on two specific values within the array? For instance:
$arr = array(
array('a' => array('field1' => 'Abc', 'field2' => 'Def'), 'b' => 0)
array('a' => array('field1' => 'Ghi', 'field2' => 'Jkl'), 'b' => 0)
);
I want to sort this array based on the $arr[$i]['a']['field1...
Is there a way to get the query after mysqli prepares it? My query is messing up:
$query = "UPDATE event SET group=?, boxed=?, name=?, location=?, time=?, day=?, type=? WHERE id=? LIMIT 1";
if($stmt = $db -> prepare($query))
{
$stmt -> bind_param("iisssssi", $group, $boxed, $name, $location, $time, $day, $etype, $id);
...
i have a script for exporting results of a mysql query as a csv file. The thing is that i use jquery to access the script. I need to know how i can return the data (already in csv format) with jquery. In other words, just to make myself clear because my english is a bit poor, when the user presses a button in the html file, a post reques...
Hi, I'm trying to create a simple function which returns me a date with a certain number of subtracted days from now, so something like this but I dont know the date classes well:
<?
function get_offset_hours ($hours) {
return date ("Y-m-d H:i:s", strtotime (date ("Y-m-d H:i:s") /*and now?*/));
}
function get_offset_days ($days) {
...
Hi,
I wonder how PHP handles true/false comparison internally. I understand that true is defined as 1 and false is defined as 0. When I do if("a"){ echo "true";} it echos "true". How does PHP recognize "a" as 1 ?
...
This is an subjective question, I need your feels and thoughts about coding standards, and formatting practices.
PHP Zend coding standard requires to write multiline function calls like this:
$returnedValue = $object->longMethodName(
$argument1,
$otherArgument,
42
);
I think the following approach is more readable:
$retu...
How would I split a HTML formatted file into several HTML files (complete with with HTML, HEAD and BODY tags) with PHP? I would have a placeholder tag (something like <div class='placeholder'></div> ) for all the places I want to cut.
Thanks.
...
I have another csv file where I am trying to do a simple word filter. For example, my text.csv file looks something like this:
name, age, hobbies
Tom, 8, "football, soccer, baseball, wii, star wars, books"
Bill, 9, "football, baseball, ice hockey, basketball"
Sue, 8, "baseball, soccer, volleyball, bicycles, skating"
Mike, 8, "basketbal...
how would i a)include a php script that is outside the web root (would it really be just a simple ../file.php), b)post form data to a php script outside the web root. I'm led to believe this is a corner stone to php security.
...
Language: OO PHP 5+
DB: MySQL
I am trying to insert data from a form using radio buttons by getting their value and then inserting into a MySQL database. I can insert anything on the form that uses a textfield to collect data, but when I try to insert the value of a radio button the insert just leaves the corresponding db field blank. I...
In PHP I'd like to do this:
switch (function_foo($bar,$bar2)) {
case $fu:
*Do Stuff*
break;
case $fubar:
*Do Other Stuff*
break;
}
Is this a terrible idea? Will it work?
...