PHWinfo banniere

Titres
PORTAIL ANNUAIRE ARTICLES COMPARATEUR HÉBERGEURS DEVIS FORUMS RÉDUCTEUR D'URL
Précédent   PHWinfo > Autres forums > Forum Programmation & Conception > comp.lang.php > %s , %d, etc
S'inscrire FAQ Membres Recherche Messages du jour Marquer les forums comme lus
%s , %d, etc

Réponse
 
LinkBack Outils de la discussion
Vieux 26/04/2008, 16h31   #1
AJ
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut %s , %d, etc

Thanks in advance to anyone who can .

I just have a quick question - I cannot find an answer at php.net.

I have some define elements, for example:

define('EMAIL_GREET_MR', 'Dear Mr. %s,' . "\n\n");

define('TEXT_CITY_UNLISTED', 'If your city is not listed please
click&nbsp;<a href="%s""><u>here</u></a>');

define('PREVNEXT_TITLE_PAGE_NO', 'Page %d');

They certainly look like variables but I can find no references to them
on php.net or in my php books. I have tried to figure out where these
are declared and I'm having trouble. Could someone tell me about these
or point me to a good source of info on the topic?

I'm still learning so be kind!

Thanks again.

AJ
  Réponse avec citation
Vieux 26/04/2008, 16h48   #2
Jensen Somers
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: %s , %d, etc

Hello,

AJ wrote:
> Thanks in advance to anyone who can .
>
> I just have a quick question - I cannot find an answer at php.net.
>
> I have some define elements, for example:
>
> define('EMAIL_GREET_MR', 'Dear Mr. %s,' . "\n\n");
>
> define('TEXT_CITY_UNLISTED', 'If your city is not listed please
> click&nbsp;<a href="%s""><u>here</u></a>');
>
> define('PREVNEXT_TITLE_PAGE_NO', 'Page %d');
>
> They certainly look like variables but I can find no references to them
> on php.net or in my php books. I have tried to figure out where these
> are declared and I'm having trouble. Could someone tell me about these
> or point me to a good source of info on the topic?
>
> I'm still learning so be kind!
>
> Thanks again.
>
> AJ


You can find some information on the "sprintf" page at
http://www.php.net/manual/en/function.sprintf.php regarding these things.

- Jensen
  Réponse avec citation
Vieux 28/04/2008, 05h39   #3
Lars Eighner
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: %s , %d, etc

In our last episode, <yqidnWjAyK5H047VnZ2dneKdnZydnZ2d@giganews.com>, the
lovely and talented Jensen Somers broadcast on comp.lang.php:

> Hello,


> AJ wrote:
>> Thanks in advance to anyone who can .
>>
>> I just have a quick question - I cannot find an answer at php.net.
>>
>> I have some define elements, for example:
>>
>> define('EMAIL_GREET_MR', 'Dear Mr. %s,' . "\n\n");
>>
>> define('TEXT_CITY_UNLISTED', 'If your city is not listed please
>> click&nbsp;<a href="%s""><u>here</u></a>');
>>
>> define('PREVNEXT_TITLE_PAGE_NO', 'Page %d');
>>
>> They certainly look like variables but I can find no references to them
>> on php.net or in my php books. I have tried to figure out where these
>> are declared and I'm having trouble. Could someone tell me about these
>> or point me to a good source of info on the topic?
>>
>> I'm still learning so be kind!
>>
>> Thanks again.
>>
>> AJ


> You can find some information on the "sprintf" page at
> http://www.php.net/manual/en/function.sprintf.php regarding these things.


What is more, there is a standard C library function "sprintf," so a
sprintf-like function is found in many languages (e.g. perl) and many C
applications, and there is a unix-like command 'printf'. All are very
similar in formating. The PHP manual page looks fairly complete to me, but
if you just don't get it, you can probably find tutorials for other
languages that should give you a better idea of what is going on.

--
Lars Eighner <http://larseighner.com/> usenet@larseighner.com
Countdown: 267 days to go.
  Réponse avec citation
Réponse


Outils de la discussion

Règles de messages
Vous ne pouvez pas créer de nouvelles discussions
Vous ne pouvez pas envoyer des réponses
Vous ne pouvez pas envoyer des pièces jointes
Vous ne pouvez pas modifier vos messages

Les balises BB sont activées : oui
Les smileys sont activés : oui
La balise [IMG] est activée : oui
Le code HTML peut être employé : non
Trackbacks are oui
Pingbacks are oui
Refbacks are oui


Fuseau horaire GMT +1. Il est actuellement 10h55.


Édité par : vBulletin® version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC5 Tous droits réservés.
Version française #16 par l'association vBulletin francophone
PHWinfo est un site Éducation Sans Frontières ©2000-2008
Ad Management by RedTyger
©Tous droits réservés par les parties respectives
Page generated in 0,11188 seconds with 11 queries