{"id":666,"date":"2013-12-10T12:54:51","date_gmt":"2013-12-10T12:54:51","guid":{"rendered":"http:\/\/www.masterlevel.de\/blog\/?p=666"},"modified":"2013-12-10T13:06:02","modified_gmt":"2013-12-10T13:06:02","slug":"php-scriptname-ohne-suffix","status":"publish","type":"post","link":"https:\/\/www.masterlevel.de\/blog\/php-scriptname-ohne-suffix\/","title":{"rendered":"php: Scriptname ohne Suffix"},"content":{"rendered":"<p>Jaja, ist wirklich kein Problem. Trotzdem brauch ich das immer wieder: die Variante &#8222;Scriptname ohne Endung&#8220; bzw. Suffix oder ganz exakt:Dateinamenserweiterung.<\/p>\n<pre class=\"brush: php; title: ; notranslate\" title=\"\">\r\n\r\n$t = explode('\/',$_SERVER&#x5B;'PHP_SELF']);\r\n$u = explode(&quot;.&quot;,end($t));\r\n$seite = $u&#x5B;0];\r\n\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Jaja, ist wirklich kein Problem. Trotzdem brauch ich das immer wieder: die Variante &#8222;Scriptname ohne Endung&#8220; bzw. Suffix oder ganz exakt:Dateinamenserweiterung. $t = explode(&#8218;\/&#8216;,$_SERVER&#x5B;&#8217;PHP_SELF&#8216;]); $u = explode(&quot;.&quot;,end($t)); $seite = $u&#x5B;0];<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[93,94],"tags":[],"class_list":["post-666","post","type-post","status-publish","format-standard","hentry","category-php","category-snippets"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>php: Scriptname ohne Suffix - masterlevel<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.masterlevel.de\/blog\/php-scriptname-ohne-suffix\/\" \/>\n<meta name=\"twitter:label1\" content=\"Verfasst von\" \/>\n\t<meta name=\"twitter:data1\" content=\"J. Adler\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.masterlevel.de\\\/blog\\\/php-scriptname-ohne-suffix\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.masterlevel.de\\\/blog\\\/php-scriptname-ohne-suffix\\\/\"},\"author\":{\"name\":\"J. Adler\",\"@id\":\"https:\\\/\\\/www.masterlevel.de\\\/blog\\\/#\\\/schema\\\/person\\\/e6868eda89eb09db99b63d9d8dd4b63f\"},\"headline\":\"php: Scriptname ohne Suffix\",\"datePublished\":\"2013-12-10T12:54:51+00:00\",\"dateModified\":\"2013-12-10T13:06:02+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.masterlevel.de\\\/blog\\\/php-scriptname-ohne-suffix\\\/\"},\"wordCount\":41,\"commentCount\":0,\"articleSection\":[\"PHP\",\"Snippets\"],\"inLanguage\":\"de\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/www.masterlevel.de\\\/blog\\\/php-scriptname-ohne-suffix\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.masterlevel.de\\\/blog\\\/php-scriptname-ohne-suffix\\\/\",\"url\":\"https:\\\/\\\/www.masterlevel.de\\\/blog\\\/php-scriptname-ohne-suffix\\\/\",\"name\":\"php: Scriptname ohne Suffix - masterlevel\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.masterlevel.de\\\/blog\\\/#website\"},\"datePublished\":\"2013-12-10T12:54:51+00:00\",\"dateModified\":\"2013-12-10T13:06:02+00:00\",\"author\":{\"@id\":\"https:\\\/\\\/www.masterlevel.de\\\/blog\\\/#\\\/schema\\\/person\\\/e6868eda89eb09db99b63d9d8dd4b63f\"},\"inLanguage\":\"de\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.masterlevel.de\\\/blog\\\/php-scriptname-ohne-suffix\\\/\"]}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.masterlevel.de\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.masterlevel.de\\\/blog\\\/\",\"name\":\"masterlevel\",\"description\":\"Manche Sachen vergi\u00dft man, weil man sie nicht oft braucht - deshalb stehen sie hier...\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.masterlevel.de\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"de\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.masterlevel.de\\\/blog\\\/#\\\/schema\\\/person\\\/e6868eda89eb09db99b63d9d8dd4b63f\",\"name\":\"J. Adler\",\"url\":\"https:\\\/\\\/www.masterlevel.de\\\/blog\\\/author\\\/admin\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"php: Scriptname ohne Suffix - masterlevel","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.masterlevel.de\/blog\/php-scriptname-ohne-suffix\/","twitter_misc":{"Verfasst von":"J. Adler"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.masterlevel.de\/blog\/php-scriptname-ohne-suffix\/#article","isPartOf":{"@id":"https:\/\/www.masterlevel.de\/blog\/php-scriptname-ohne-suffix\/"},"author":{"name":"J. Adler","@id":"https:\/\/www.masterlevel.de\/blog\/#\/schema\/person\/e6868eda89eb09db99b63d9d8dd4b63f"},"headline":"php: Scriptname ohne Suffix","datePublished":"2013-12-10T12:54:51+00:00","dateModified":"2013-12-10T13:06:02+00:00","mainEntityOfPage":{"@id":"https:\/\/www.masterlevel.de\/blog\/php-scriptname-ohne-suffix\/"},"wordCount":41,"commentCount":0,"articleSection":["PHP","Snippets"],"inLanguage":"de","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.masterlevel.de\/blog\/php-scriptname-ohne-suffix\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.masterlevel.de\/blog\/php-scriptname-ohne-suffix\/","url":"https:\/\/www.masterlevel.de\/blog\/php-scriptname-ohne-suffix\/","name":"php: Scriptname ohne Suffix - masterlevel","isPartOf":{"@id":"https:\/\/www.masterlevel.de\/blog\/#website"},"datePublished":"2013-12-10T12:54:51+00:00","dateModified":"2013-12-10T13:06:02+00:00","author":{"@id":"https:\/\/www.masterlevel.de\/blog\/#\/schema\/person\/e6868eda89eb09db99b63d9d8dd4b63f"},"inLanguage":"de","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.masterlevel.de\/blog\/php-scriptname-ohne-suffix\/"]}]},{"@type":"WebSite","@id":"https:\/\/www.masterlevel.de\/blog\/#website","url":"https:\/\/www.masterlevel.de\/blog\/","name":"masterlevel","description":"Manche Sachen vergi\u00dft man, weil man sie nicht oft braucht - deshalb stehen sie hier...","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.masterlevel.de\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"de"},{"@type":"Person","@id":"https:\/\/www.masterlevel.de\/blog\/#\/schema\/person\/e6868eda89eb09db99b63d9d8dd4b63f","name":"J. Adler","url":"https:\/\/www.masterlevel.de\/blog\/author\/admin\/"}]}},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.masterlevel.de\/blog\/wp-json\/wp\/v2\/posts\/666","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.masterlevel.de\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.masterlevel.de\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.masterlevel.de\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.masterlevel.de\/blog\/wp-json\/wp\/v2\/comments?post=666"}],"version-history":[{"count":4,"href":"https:\/\/www.masterlevel.de\/blog\/wp-json\/wp\/v2\/posts\/666\/revisions"}],"predecessor-version":[{"id":669,"href":"https:\/\/www.masterlevel.de\/blog\/wp-json\/wp\/v2\/posts\/666\/revisions\/669"}],"wp:attachment":[{"href":"https:\/\/www.masterlevel.de\/blog\/wp-json\/wp\/v2\/media?parent=666"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.masterlevel.de\/blog\/wp-json\/wp\/v2\/categories?post=666"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.masterlevel.de\/blog\/wp-json\/wp\/v2\/tags?post=666"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}