But if there is an error in the SELECT query (either syntax error, or
reference to missing table), then no exception is raised, and control
just continues in the try block with a null result from the query.
Is this the intended behaviour?
Hey, it's really fun I was looking here and on
And also my question is :
Why did the PDO creators (Wez the King?) decide to choose the silent
mode for being the default one ?
Why not defining the ERRMODE_WARNING by default ?
Or perhaps I misunderstand something, and I would be very happy to learn
a bit :)
Thx
Cyril
--
PHP Database
Read on otn :
PDO_ERRMODE_SILENT
This is the default mode; it will simply set the error code for you to
inspect using the errorCode() and errorInfo() methods of both the
statement and database handle objects.
if (!$dbh-exec($sql)) {
echo $dbh-errorCode() . br;
$info =
Hey, I need some help.
I am trying to parse a forum post using php, but it parses it everytime it
sees the letter, not the thing in quotes. Any help?
function bbcodereplace($subject){
// $document should contain an HTML document.
// This will remove HTML tags, javascript sections
// and white
Nathan Heaps wrote:
I am trying to parse a forum post using php, but it parses it
everytime it
sees the letter, not the thing in quotes.
What letter? What thing in quotes?
-J
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Wait, its a different thing now. You see, I am trying to replace phpbb's
bbcode with working html code, but what makes it hard is that phpbb inserts
a number after SOME of the bbcode tags. Here is what I have so far:
function bbcodereplace($subject){
$search = array
Hi,
I've been searching all day through all the reasources i can find for a
pointer in the right direction. I've just started a clean install of my
LAMP system, and got to PHP. On ./configure it goes through all the
normal processes untill it reaches the -lmysqladmin line, where it kicks
out
// /\[i(.*?)\](.*?)\[\/i(.*?)\]/, // Italics
/\[u(.*?)\](.*?)\[\/u(.*?)\]/, // Underline
/\[img(.*?)\](.*?)\[\/img(.*?)\]/, // Image
/\[b(.*?)\](.*?)\[\/b(.*?)\]/); // Bold
Change to
/\[i:(.*?)\](.*?)\[\/i:(.*?)\]/, // Italics
nevermind, I got it fixed. Just had to rearrange it. it was sensing the i in
img as italic so if you put it first it would work.
- Original Message -
From: Liber [EMAIL PROTECTED]
To: 'Nathan Heaps' [EMAIL PROTECTED]; 'John Hicks'
[EMAIL PROTECTED]
Cc: php-db@lists.php.net
Sent:
Ok, scratch that, new problem. what can I replace (.*?) with in order for
php to recognise a multi-line quote/bold/italic/code/whatever?
- Original Message -
From: Liber [EMAIL PROTECTED]
To: 'Nathan Heaps' [EMAIL PROTECTED]; 'John Hicks'
[EMAIL PROTECTED]
Cc: php-db@lists.php.net
10 matches
Mail list logo