Jump to content

Search the Community

Showing results for tags 'abbreviated if-else statements'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • W3Schools
    • General
    • Suggestions
    • Critiques
  • HTML Forums
    • HTML/XHTML
    • CSS
  • Browser Scripting
    • JavaScript
    • VBScript
  • Server Scripting
    • Web Servers
    • Version Control
    • SQL
    • ASP
    • PHP
    • .NET
    • ColdFusion
    • Java/JSP/J2EE
    • CGI
  • XML Forums
    • XML
    • XSLT/XSL-FO
    • Schema
    • Web Services
  • Multimedia
    • Multimedia
    • FLASH

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests


Languages

Found 1 result

  1. CHALLENGE (WELL, KIND OF): Please find below two sets of code. The first is a short-hand snippet of code fits that within a larger block of code. The second is my own long-hand interpretation of what it means. SHORT-HAND: $str_browser_language = !empty($_SERVER['HTTP_ACCEPT_LANGUAGE']) ? strtok(strip_tags($_SERVER['HTTP_ACCEPT_LANGUAGE']), ',') : ''; $str_browser_language = !empty($_GET['language']) ? $_GET['language'] : $str_browser_language; LONG-HAND: if (!empty($_SERVER['HTTP_ACCEPT_LANGUAGE'])) { $str_browser_language = strtok(strip_tags($_SERVER['HTTP_ACCEPT_LANGUAGE']), ','); } else { if (!empty($_GET['language'])) { $str_browser_language = $_GET['language']; } else { $str_browser_language = ''; } } QUESTION: Is my interpretation correct? If not, please explain, in what manner I have erred. Roddy
×
×
  • Create New...