Sophie

Sophie

distrib > Mageia > 4 > x86_64 > by-pkgid > f800694edefe91adea2624f711a41a2d > files > 8501

php-manual-en-5.5.7-1.mga4.noarch.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
 <head>
  <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  <title>Get last error message on the object</title>

 </head>
 <body><div class="manualnavbar" style="text-align: center;">
 <div class="prev" style="text-align: left; float: left;"><a href="intlcalendar.geterrorcode.html">IntlCalendar::getErrorCode</a></div>
 <div class="next" style="text-align: right; float: right;"><a href="intlcalendar.getfirstdayofweek.html">IntlCalendar::getFirstDayOfWeek</a></div>
 <div class="up"><a href="class.intlcalendar.html">IntlCalendar</a></div>
 <div class="home"><a href="index.html">PHP Manual</a></div>
</div><hr /><div id="intlcalendar.geterrormessage" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">IntlCalendar::getErrorMessage</h1>
  <h1 class="refname">intlcal_get_error_message</h1>
  <p class="verinfo">(PHP 5.5.0, PECL &gt;= 3.0.0a1)</p><p class="refpurpose"><span class="refname">IntlCalendar::getErrorMessage</span> -- <span class="refname">intlcal_get_error_message</span> &mdash; <span class="dc-title">Get last error message on the object</span></p>

 </div>

 <div class="refsect1 description" id="refsect1-intlcalendar.geterrormessage-description">
  <h3 class="title">Description</h3>
  <p class="para">Object oriented style (method):</p>
   <div class="methodsynopsis dc-description">
   <span class="modifier">public</span> <span class="type">string</span> <span class="methodname"><strong>IntlCalendar::getErrorMessage</strong></span>
    ( <span class="methodparam">void</span>
    )</div>

  <p class="para rdfs-comment">Procedural style:</p>
  <div class="methodsynopsis dc-description">
   <span class="type">string</span> <span class="methodname"><strong>intlcal_get_error_message</strong></span>
    ( <span class="methodparam"><span class="type"><a href="class.intlcalendar.html" class="type IntlCalendar">IntlCalendar</a></span> <code class="parameter">$calendar</code></span>
   )</div>

  <p class="para rdfs-comment">
   Returns the error message (if any) associated with the error reported by
    <span class="function"><a href="intlcalendar.geterrorcode.html" class="function">IntlCalendar::getErrorCode()</a></span> or
    <span class="function"><a href="intlcalendar.geterrorcode.html" class="function">intlcal_get_error_code()</a></span>. If there is no associated
   error message, only the string representation of the name of the error
   constant will be returned.  Otherwise, the message also includes a message
   set on the side of the PHP binding.
  </p>
 </div>


 <div class="refsect1 parameters" id="refsect1-intlcalendar.geterrormessage-parameters">
  <h3 class="title">Parameters</h3>
  <dl>

   <dt>

    <span class="term"><em><code class="parameter">calendar</code></em></span>
    <dd>

     <p class="para">
      The calendar object, on the procedural style interface.
     </p>
    </dd>

   </dt>

  </dl>

 </div>


 <div class="refsect1 returnvalues" id="refsect1-intlcalendar.geterrormessage-returnvalues">
  <h3 class="title">Return Values</h3>
  <p class="para">
   The error message associated with last error that occurred in a function call
   on this object, or a string indicating the non-existance of an error.
  </p>
 </div>


 <div class="refsect1 examples" id="refsect1-intlcalendar.geterrormessage-examples">
  <h3 class="title">Examples</h3>
  <p class="para">
   <div class="example" id="example-2603">
   <p><strong>Example #1  <span class="function"><strong>IntlCalendar::getErrorMessage()</strong></span></strong></p>
    <div class="example-contents">
<div class="phpcode"><code><span style="color: #000000">
<span style="color: #0000BB">&lt;?php<br />$cal&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #0000BB">IntlCalendar</span><span style="color: #007700">::</span><span style="color: #0000BB">createInstance</span><span style="color: #007700">(</span><span style="color: #DD0000">'UTC'</span><span style="color: #007700">,&nbsp;</span><span style="color: #DD0000">'en_US'</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">var_dump</span><span style="color: #007700">(</span><span style="color: #0000BB">$cal</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">getErrorMessage</span><span style="color: #007700">());<br /><br /></span><span style="color: #0000BB">$cal</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">getWeekendTransition</span><span style="color: #007700">(</span><span style="color: #0000BB">IntlCalendar</span><span style="color: #007700">::</span><span style="color: #0000BB">DOW_WEDNESDAY</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">var_dump</span><span style="color: #007700">(</span><span style="color: #0000BB">$cal</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">getErrorMessage</span><span style="color: #007700">());</span>
</span>
</code></div>
    </div>

    <div class="example-contents"><p>The above example will output:</p></div>
    <div class="example-contents screen">
<div class="cdata"><pre>
string(12) &quot;U_ZERO_ERROR&quot;
string(82) &quot;intlcal_get_weekend_transition: Error calling ICU method: U_ILLEGAL_ARGUMENT_ERROR&quot;
</pre></div>
    </div>
   </div>
  </p>
 </div>


</div><hr /><div class="manualnavbar" style="text-align: center;">
 <div class="prev" style="text-align: left; float: left;"><a href="intlcalendar.geterrorcode.html">IntlCalendar::getErrorCode</a></div>
 <div class="next" style="text-align: right; float: right;"><a href="intlcalendar.getfirstdayofweek.html">IntlCalendar::getFirstDayOfWeek</a></div>
 <div class="up"><a href="class.intlcalendar.html">IntlCalendar</a></div>
 <div class="home"><a href="index.html">PHP Manual</a></div>
</div></body></html>