php

how can i get mysql results with alphabetical pagination

how can i get mysql results with alphabetical pagination i.e i have 2 fields i.e id and name in mysql table and following html links for pagination A B C D E F G ....... by clicking on A i want to get results names starting with A how can i do that with php ...

print_r not understanding a portion of the output.

I run a print_r command on $_POST and I am getting the following response: s:1289:"Array ( [id_master] => 12 [id_controller] => 4 [JSON] => {"uuid":"i~b1dad2c95c3efdc8521c84cd2891084289b9754b","relsno":102} )"; Any idea what the s:1289: is? ...

Calendar always shows 7:00 no matter what the data in the table says - Basically the variable is always set to 7:00.

Hi Guys, I have a table with data exactly like this: ID Heading Description Time Location Start_Date End_Date 63 Wed Serv Small group 19:00:00 null 2010-10-13 null 70 Fall Harvest Calvary null Pepin, Wi 2010-10-30 null My Calendar shows the events on the correct dates, but the ti...

move_uploaded_file() can't open stream

I'm trying to upload files via Pycurl through POST, using a PHP script on the receiving end. For some reason the PHP part seems to cause an error. I've distilled it down to two short test scripts. import pycurl UPLOADURL = "http://127.0.0.1/~nevon/receive.php" #URL to the PHP script PATH = "/home/nevon/Desktop/testfile" #path to the fi...

trigger_error vs. throwing exceptions

A similar question was asked here, but as the answers didn't answer my question, I'm asking: I've almost never used trigger_error, always thrown exceptions instead, since in my mind errors are legacy. But I've changed my mind, I think they can co-exist. There are cases when triggering errors make more sense. I'm updating this library, ...

foreach invalid argument and undefined variable

Done....moderators.close this post...Thanks everyone for helping me out. ...

1 way encryption and 2 way encrption

what's the difference between 1 way encryption and 2 way encryption with php and MySQL? ...

Best way to develop/manage/design recurring tasks/calendar

An example of what I'm talking about is similar to Google Calendar. When a new recurring task is created. After creating the recurring task "template" - which all of the individual tasks are based on, do you create all of the individual tasks and store them in the database? or do you just store the "template" recurring events and their...

Prestashop 1.3.2 FedEx shipping module

Im having a serious problem with a prestashop shipping module for FedEx. I know this might not the place for this, but Im really running out of options. Was wondering if I could get some help... First of all Prestashop is a open source E-commerce platform. Now the problem is it has POOR shipping module capabilities. I was on the search ...

Merge two mp3 php

Hello, Do you know a class to merge two mp3 in php ? I've found nothing serious on google. Thank you ! ...

Symfony fails on sfValidatorRegex

I'm using the following line: $this->validatorSchema['name'] = new sfValidatorRegex( array('pattern' => '<my_regex>', 'must_match' => false), array('invalid' => 'Invalid name')); But "must_match" option is not working and I don't know why. Whatever I use true or false, it works like always: detect the expression and if it's on the te...

Recommend a web service that handles location within a specific radius?

We have a client that wants a store locator on their website. I've been asked to find a webservice that will allow us to send a zipcode as a request and have it return locations within x radius. We found this, but it's maintained by a single person, and doesn't look like it gets updated or supported very well. We're looking for something...

custom errorhandler does not handle critical errors (php)

Hi. This is the main part of my errorhandler: function my_error_handler($errno, $errstr, $errfile, $errline){ $errno = $errno & error_reporting(); if($errno == 0) return; if(!defined('E_STRICT')) define('E_STRICT', 2048); if(!defined('E_RECOVERABLE_ERROR')) define('E_RECOVERABLE_ERROR', 4096); $error = "...

Trouble structuring MySQL query with one-to-many over multiple tables

I have a blog-style app that allows users to tag each post with topics. I keep this data in three separate tables: posts (for the actual blog posts), topics (for the various tags), and posts_topics (a table that stores the relationships between the two). In order to keep the MVC structure (I'm using Codeigniter) as clean as possible, I...

compressing a folder into different formats in php

hey guys , im dealing with a script that it should compress and folder and make it ready in 3 versions : 7z zip tar.gz surely i did found a way on how to make a zip file out of a folder in php by using a zip compression class http://www.phpclasses.org/package/2322-PHP-Create-ZIP-file-archives-and-serve-for-download.html but for 7...

mysql php forum list

here are my tables topics -id -title -category_id posts -id -topic_id -user_id -date -time -txt user -id -username i want to list for a category every topic with the following information the author's username (who posted first), number of replies,the name of the last reply's author, and the date of last post sorted by the date of ...

CakePHP: changing link to 'tags/index/php' to just 'tags/php'

Hi, I have a controller called TagsController that takes the tag name from the url in the index action to get a list of projects with that tag. <?php foreach($tags as $tag){ echo "<span class='homepagetags'>".$html->link($tag['t']['tag'], array('controller' => 'tags', $tag['t']['tag'])) . "</span> x " . $tag[0]['NumOccurrances'] ...

How to Upload a Video?

I want to know how to upload a video like on youtube, vimeo etc to get a final flash video. I'm using PHP. I have this HTML form: <form action="upload.php" method="post" enctype="multipart/form-data"> <input type="file" name="upload_video" /> </form> So what should I do if the user has uploaded a video for example in .mov or othe...

Simple jQuery gallery and sortable: one last missing piece...

Hey there, So, I've built-up a little gallery using a few plug-ins and some custom code. This is for a few photography website portfolios. So far, I've got the thumbnails in a UL on the left, and the larger image on the right. I've got some hover effects on the thumbnails, and onClick they fadeOut the larger image, swap SRC, load, then ...

php creating zips without path to files inside the zip

hi all, I'm trying to use php to create a zip file (which it does - taken from this page - http://davidwalsh.name/create-zip-php), however inside the zip file are all of the folder names to the file itself. Is it possible to just have the file inside the zip minus all the folders? Here's my code: function create_zip($files = array(),...