php-general Digest 10 May 2011 14:41:52 -0000 Issue 7306
Topics (messages 312737 through 312742):
Re: Bold links
312737 by: Adam Richardson
312738 by: admin.buskirkgraphics.com
312742 by: tedd
Re: Error Reporting/Display Errors Issues?
312739 by: xianhua zhou
312741 by: admin.buskirkgraphics.com
Re: mysql error
312740 by: xianhua zhou
Administrivia:
To subscribe to the digest, e-mail:
[email protected]
To unsubscribe from the digest, e-mail:
[email protected]
To post to the list, e-mail:
[email protected]
----------------------------------------------------------------------
--- Begin Message ---
On Mon, May 9, 2011 at 5:56 PM, tedd <[email protected]> wrote:
> At 1:39 PM -0400 5/7/11, <[email protected]> wrote:
>
>> <?php global $current_user;
>> get_currentuserinfo();
>>
>> echo 'Welcome <B>' . $current_user->user_firstname . "</B>\n";
>> echo '<B>' . $current_user->user_lastname . "</B>\n";
>> ?>
>>
>> Richard L. Buskirk
>>
>
> Really?
>
> How does the blind via readers, such as JAWS, understand what a <B> is?
>
> First, never use <B> -- or <I> for that matter.
>
> Second, use <strong> or <em> instead. Readers can understand and render
> STRONG and EMPHASIZED text, but not <B> and <I> text -- those tags mean
> nothing and that's the reason why they are not encouraged for use and even
> removed from XHTML.
>
> Third, if neither of those tags (i.e., <strong> or <em> ) work for you,
> they try using a class (or an id) with a css rule of:
>
Ted is right that the teaching in (X)HTML for the past several years has
been to avoid use of <b> and <i> tags, essentially replacing them with
<strong> and <em> tags, respectively.
However, (X)HTML5 is changing the semantics of the <b> and <i> tags so
they're use is again being encouraged (when appropriate):
http://dev.w3.org/html5/spec/Overview.html#the-i-element
http://dev.w3.org/html5/spec/Overview.html#the-b-element
<http://dev.w3.org/html5/spec/Overview.html#the-b-element>The intention is
to improve the semantics available to web developers, with one of the hopes
being that these nuanced differences will eventually enhance the experience
of those who are using screen readers.
So, while I don't necessarily recommend using a lot of <b> and <i> tags now,
it's likely that in the near future their use will again be encouraged as
HTML5 becomes better supported.
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
--- End Message ---
--- Begin Message ---
Thank you Adam,
The answer was not in haste, but the most common direction of a lot of
browsers.
Personally I encourage the use of CSS over explicitly presentational HTML
markup.
The answer was to explain that it was not a php functionality.
Some tend to toot a broken horn, about broken software and not see the
question for what it is...
Richard L. Buskirk
-----Original Message-----
From: Adam Richardson [mailto:[email protected]]
Sent: Tuesday, May 10, 2011 2:57 AM
To: PHP-General
Subject: Re: [PHP] Bold links
On Mon, May 9, 2011 at 5:56 PM, tedd <[email protected]> wrote:
> At 1:39 PM -0400 5/7/11, <[email protected]> wrote:
>
>> <?php global $current_user;
>> get_currentuserinfo();
>>
>> echo 'Welcome <B>' . $current_user->user_firstname .
"</B>\n";
>> echo '<B>' . $current_user->user_lastname . "</B>\n";
>> ?>
>>
>> Richard L. Buskirk
>>
>
> Really?
>
> How does the blind via readers, such as JAWS, understand what a <B> is?
>
> First, never use <B> -- or <I> for that matter.
>
> Second, use <strong> or <em> instead. Readers can understand and render
> STRONG and EMPHASIZED text, but not <B> and <I> text -- those tags mean
> nothing and that's the reason why they are not encouraged for use and even
> removed from XHTML.
>
> Third, if neither of those tags (i.e., <strong> or <em> ) work for you,
> they try using a class (or an id) with a css rule of:
>
Ted is right that the teaching in (X)HTML for the past several years has
been to avoid use of <b> and <i> tags, essentially replacing them with
<strong> and <em> tags, respectively.
However, (X)HTML5 is changing the semantics of the <b> and <i> tags so
they're use is again being encouraged (when appropriate):
http://dev.w3.org/html5/spec/Overview.html#the-i-element
http://dev.w3.org/html5/spec/Overview.html#the-b-element
<http://dev.w3.org/html5/spec/Overview.html#the-b-element>The intention is
to improve the semantics available to web developers, with one of the hopes
being that these nuanced differences will eventually enhance the experience
of those who are using screen readers.
So, while I don't necessarily recommend using a lot of <b> and <i> tags now,
it's likely that in the near future their use will again be encouraged as
HTML5 becomes better supported.
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
--- End Message ---
--- Begin Message ---
At 3:53 PM -0700 5/9/11, Micky Hulse wrote:
On Mon, May 9, 2011 at 2:56 PM, tedd <[email protected]> wrote:
Really?
How does the blind via readers, such as JAWS, understand what a <B> is?
First, never use <B> -- or <I> for that matter.
Second, use <strong> or <em> instead. Readers can understand and render
STRONG and EMPHASIZED text, but not <B> and <I> text -- those tags mean
nothing and that's the reason why they are not encouraged for use and even
removed from XHTML.
Third, if neither of those tags (i.e., <strong> or <em> ) work for you, they
try using a class (or an id) with a css rule of:
[OT]
Tedd, it seems like you are spreading a little bit of mis-information here.
Micky:
I see that you brought your authority to the argument, namely:
http://html5doctor.com/i-b-em-strong-element/
So, allow me to bring mine -- my information/position stems from my
understanding derived from both daily practice and constant reading.
In addition to reading links like the above (which I read btw), I
also read several list provided by disability concerns, such as
"webdev.lists.d.umn.edu" being the best. In addition to all that, I
also read several technical books each week re these subjects.
For example, within this last month I've purchased and read HTML5 by
Lawson, Smashing CSS by Meyer, 100 Things by Weinschenk, Learning Web
Design by Robbins, Designing with the Mind in Mind by Johnson, Forms
that work by Jarret, Build your own web site the right way by Lloyd,
PHP 5.3 by Doyle, and Expert PHP and MySQL by Cuniosoa. That's a lot
of reading, -- so I think I keep up with what's going on.
While it is true that html5 brought back tags such as <b> and <i>,
but it has also brought back <table> for presentation. I leave the
reader (and the future) to judge the wisdom of that decision.
I think we all realize the problems that these tags bring to the
table (no pun intended). We can either continue to resolve the
problems they present or we can resort back to the way things were.
As for me, I choose to never use <b> and <i> for anything PERIOD and
to speak out against their use whenever I can. As for <table> in
presentation, I am still undecided. While I would never use tables
for the presentation of text, I often use simple tables (i.e., no
nesting) for holding forms together. However, I am leaning toward not
using tables for that either.
The world is changing and I don't think any organization can dictate
what is the right/wrong way to do anything. But the good thing here
is that we are left to our own judgement as to what we support and
what we condemn. In my judgment, the <b> and <i> tags present more
problems than they solve so I will continue to not use those tags and
speak against them.
Cheers,
tedd
--
-------
http://sperling.com/
--- End Message ---
--- Begin Message ---
You may need to check the running php code, those values can be
changed during runtime.
2011/5/10 Mike Mackintosh <[email protected]>:
> Anyone else notice PHP throwing Warning and Notices even when display errors
> and error reporting disabled?
>
> I compiled PHP with the following:
>
> './configure' '--prefix=/usr/local/php-5.3.3' '--enable-cli'
> '--disable-debug' '--disable-rpath' '--disable-static' '--with-pic'
> '--with-openssl=/usr' '--enab
> le-bcmath' '--with-bz2' '--enable-calendar' '--enable-ctype' '--with-curl'
> '--with-zlib-dir=/usr' '--with-xsl' '--enable-exif' '--enable-ftp'
> '--with-gd' '--enable-gd-native-ttf' '-
> -with-ttf' '--with-jpeg-dir=/usr' '--with-png-dir=/usr'
> '--with-freetype-dir=/usr' '--with-gettext' '--with-iconv' '--with-imap'
> '--with-kerberos=/usr' '--with-imap-ssl=/usr' '--ena
> ble-mbstring' '--with-mcrypt' '--with-mhash' '--with-mime-magic'
> '--with-mysql=/usr/local/mysql-5.1.49' '--with-pcre-regex=/usr'
> '--with-pspell=/usr' '--enable-sockets' '--enable-wd
> dx' '--with-xmlrpc' '--with-zlib=/usr' '--with-pear' '--with-layout=GNU'
> '--with-ldap' '--enable-pdo' '--enable-soap'
> '--with-apxs2=/usr/local/apache-2.2.16/bin/apxs' '--enable-pcnt
> l' '--enable-mailparse' '--enable-zip' '--with-zip=/usr' '--with-bz2=/usr'
> '--with-config-file-path=/etc'
> '--with-config-file-scan-dir=/usr/local/php-5.3.3/etc' '--with-pdo-mysql=/u
> sr/local/mysql-5.1.49' '--with-openssl=/usr'
>
> I have also set the following:
>
> display_errors => Off => Off
> display_startup_errors => Off => Off
> error_append_string => no value => no value
> error_log => no value => no value
> error_prepend_string => no value => no value
> error_reporting => 0 => 0
>
> But i continue to receive Strict/Notice and Warnings in code that i wish to
> be hidden.
>
> Any suggestions?
>
> Thanks,
>
> Mike
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--- End Message ---
--- Begin Message ---
Try this for me in a page you wish to not display errors.
<?php
error_reporting(0);
ini_set('display_errors', 0);
?>
What you are doing with this function is over riding the php.ini file and
turning off the errors on that page.
Place the code at the beginning of php before any includes.
If this works errors are turned on or your disabling function is malformed.
Richard L. Buskirk
-----Original Message-----
From: Mike Mackintosh [mailto:[email protected]]
Sent: Monday, May 09, 2011 10:34 PM
To: [email protected]
Subject: [PHP] Error Reporting/Display Errors Issues?
Anyone else notice PHP throwing Warning and Notices even when display errors
and error reporting disabled?
I compiled PHP with the following:
'./configure' '--prefix=/usr/local/php-5.3.3' '--enable-cli'
'--disable-debug' '--disable-rpath' '--disable-static' '--with-pic'
'--with-openssl=/usr' '--enab
le-bcmath' '--with-bz2' '--enable-calendar' '--enable-ctype' '--with-curl'
'--with-zlib-dir=/usr' '--with-xsl' '--enable-exif' '--enable-ftp'
'--with-gd' '--enable-gd-native-ttf' '-
-with-ttf' '--with-jpeg-dir=/usr' '--with-png-dir=/usr'
'--with-freetype-dir=/usr' '--with-gettext' '--with-iconv' '--with-imap'
'--with-kerberos=/usr' '--with-imap-ssl=/usr' '--ena
ble-mbstring' '--with-mcrypt' '--with-mhash' '--with-mime-magic'
'--with-mysql=/usr/local/mysql-5.1.49' '--with-pcre-regex=/usr'
'--with-pspell=/usr' '--enable-sockets' '--enable-wd
dx' '--with-xmlrpc' '--with-zlib=/usr' '--with-pear' '--with-layout=GNU'
'--with-ldap' '--enable-pdo' '--enable-soap'
'--with-apxs2=/usr/local/apache-2.2.16/bin/apxs' '--enable-pcnt
l' '--enable-mailparse' '--enable-zip' '--with-zip=/usr' '--with-bz2=/usr'
'--with-config-file-path=/etc'
'--with-config-file-scan-dir=/usr/local/php-5.3.3/etc' '--with-pdo-mysql=/u
sr/local/mysql-5.1.49' '--with-openssl=/usr'
I have also set the following:
display_errors => Off => Off
display_startup_errors => Off => Off
error_append_string => no value => no value
error_log => no value => no value
error_prepend_string => no value => no value
error_reporting => 0 => 0
But i continue to receive Strict/Notice and Warnings in code that i wish to
be hidden.
Any suggestions?
Thanks,
Mike
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
--- End Message ---
--- Begin Message ---
Hi Grega,
Probably you wanna define a primary key, if so, then change from
"uniqueid" to "primary key".
2011/5/6 Curtis Maurand <[email protected]>:
>
>
>
> engine=
>
> --C
>
> Grega Leskovšek wrote:
>> Can smbd please look at this sentence - I got an error and do
> not
>> know how to fix it - I am still very unfamiliar with
> MYSQL:
>>
>> CREATE TABLE log ( idlog int auto_increment
> not null, imepriimek
>> varchar(50), clock timestamp, action
> varchar(30), onfile
>> varchar(100), filesize float(6,2),
> uniqueid(idlog) );
>>
>> ERROR 1064 (42000): You have an
> error in your SQL syntax; check the
>> manual that corresponds to
> your MySQL server version for the right
>> syntax to use near
> '(idlog) )' at line 1
>>
>> -- When the sun rises I receive
> and when it sets I forgive ->
>>
> http://moj.skavt.net/gleskovs/
>> Always in Heart, Grega
> LeskovĹĄek
>>
>> --
>> PHP General
> Mailing List (http://www.php.net/)
>> To unsubscribe, visit:
> http://www.php.net/unsub.php
>>
>>
>
--- End Message ---