I want to auto-generate a readable URL from any natural text, like this:
Latest article: About German letters - Handling äöü and ß!
would ideally be changed to this
latest-article-about-german-letters-handling-aou-and-ss.html
It should work for all latin based languages and I want to avoid any escaping.
I guess this could b...
Hello.
I have a date field in a mysql table formatted like this: Y-m-d.
I want to export every post that has a date between $fromDate and all the way to $toDate
I am sure its easy but now i am totaly blocked from ideas.
I am using codeigniter if that helps.
Best Regards
Audun
...
OK, I'm probably not the first person to attempt to put together a PHP web-based interface to rsync to ease deployment, but there goes.
We have a 'QA' server locally and a 'Staging' server at Rackspace. I've set up SSH key pairings so I can rsync between the two servers and it all works great. The problem is that rsync is a bit flaky as...
I am working in PHP(with Symfony Framework) and i want to create a search based on multiple values selected from multiple selection element,
i.e there will be multiple selection dropdown elements for like countries, cities, age etc..
and the values from them will query a data table and give the desired search output. (all values are not ...
In my webapp I have a page called display.php. The script in this page behaves in different ways depending on POST and GET array content/existence, let's say: If I call this page and GET array isset, the script'll load a record using $_GET['id'], in another case, if no GET isset but isset a ceratin POST key the script'll load a random re...
I want to create wrapper class, which will enable keys duplicates while default hash does not allow it. Class should use member overloading mechanism introduced in php5, so it would imitate all the behavior standard hash has. For example, I want to have smth like
$var => obj( :values_arr -> array(
obj(:key -> 'mykey', :value -> '...
Hello All,
I anticipate this is going to be a very broad question however I shall endevour to be as concise as possible without divulging too much project critical information.
For quite some time I have been working a Content Management System. However, its vastly different to many CMS's available because of the way it handles the dis...
I have a large, PHP-based CMS that manages web pages.
All items are organized in a tree structure.
When I edit an item, the "back" button usually points to its parent item.
So, the usual workflow is navigating through the tree.
Now every now and then, the need arises for a workflow that "jumps" to other items without regard for the stru...
Hi all!,
I'm building a searchfunctionallity where a user can select the different libraries to search in with the provided keywords. Also the AND operator is supported. My problem is that when I try to search for information it gets somehow multiplied or it gets increased exponential??
I'm using a MySQL database and PHP to process the...
In python we have:
for i in range(length)
What about in PHP?
...
I'm getting � this character in my facebook app instead of "£"- I checked the mysql db and the character is being stored as £. How do i fix this? This has never happened to me before - I'm using PHP as well.
...
Is it at all possible to have a class return false instead of an object reference? It would make error handling very clean. Consider the code:
$page = new PageContent('www.google.com');
if ($page)
// do stuff
else
// handle error
...
I majored in a great software engineering program, and was taught the importance of process and the steps of a life-cycle model. I'm familiar with the classic "waterfall" model. Though we explored others, the waterfall does a good job of listing the possible tasks no matter how crafty or tricky your new-age model is. So it's a good st...
So I have a question regarding the best practice for a PHP page inserting a new row into a table. There are some required fields (aka NOT NULL) and some optional fields (can be NULL). Is it better to insert everything with one query, or just do the required fields, get the inserted ID and update the other fields with one or more other ...
Is it possible to receive the cookies set by the remote server when doing a file_get_contents request?
I need php to do a http request and store the cookies and make a second request.
...
Hi,
I am currently conducting a technical review of a web application that was developed by a third party. The used symfony framework. Are there any known issues that I should visit first? E.g. any security holes.
Thanks in advance for help.
Mark
...
I am doing a PDO::exec command on multiple updates:
$MyPdo->setAttribute(PDO::MYSQL_ATTR_USE_BUFFERED_QUERY,true);
$MyPdo->exec("update t1 set f1=1;update t2 set f1=2");
I am doing it inside a transaction, and I keep getting:
SQLSTATE[HY000]: General error: 2014
Cannot execute queries while other
unbuffered queries are active....
Hello:
I am having difficulty getting PHP(5) on Windows to work with Sqlite. After some research, I found that I have to change the php.ini file so that it reads (without semi-colons):
extension=php_pdo.dll
extension=php_sqlite.dll
I ran the phpinfo() command, and verified that my computer is reading the right php.ini file. Additi...
Hi Guys
I posted a similar question but this is slightly different. I need to scan all the text boxes on a page (there will be around 100, all with dynamic names in the form [ROW]) and then remove matching values from a drop down. I've played around with this a lot and a) can't get the windows.load function to fire in IE (Firefox is ok)...
<?php
$filename= './get/me/me_'.rand(1,100).'.zip';
header("Content-Length: " . filesize($filename));
header('Content-Type: application/zip');
header('Content-Disposition: attachment; filename=foo.zip');
readfile($filename);
?>
Hi,
I have this simple code that forces a random file download, my problem is that if I call the script tw...