{"id":698,"date":"2020-11-02T10:22:00","date_gmt":"2020-11-02T09:22:00","guid":{"rendered":"https:\/\/schaal-it.dev\/en\/?p=698"},"modified":"2023-10-22T10:23:44","modified_gmt":"2023-10-22T08:23:44","slug":"set-php-version-for-cronjobs","status":"publish","type":"post","link":"https:\/\/schaal-it.dev\/en\/blog\/set-php-version-for-cronjobs\/","title":{"rendered":"Set PHP version for cronjobs"},"content":{"rendered":"\n<p>You can not only use the PHP version of the server for a cron job.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><img fetchpriority=\"high\" decoding=\"async\" width=\"971\" height=\"757\" src=\"https:\/\/schaal-it.dev\/en\/wp-content\/uploads\/sites\/2\/2023\/10\/cron_de.jpg\" alt=\"\" class=\"wp-image-699\" srcset=\"https:\/\/schaal-it.dev\/en\/wp-content\/uploads\/sites\/2\/2023\/10\/cron_de.jpg 971w, https:\/\/schaal-it.dev\/en\/wp-content\/uploads\/sites\/2\/2023\/10\/cron_de-300x234.jpg 300w, https:\/\/schaal-it.dev\/en\/wp-content\/uploads\/sites\/2\/2023\/10\/cron_de-768x599.jpg 768w\" sizes=\"(max-width: 971px) 100vw, 971px\" \/><\/figure>\n<\/div>\n\n\n<h2 class=\"wp-block-heading\">Execute PHP Script<\/h2>\n\n\n\n<p>If you want to execute a PHP script in a cron job, you can click either on &#8220;[PHP version of the server]&#8221; or on &#8220;[PHP version of the website]&#8221; under &#8220;Command to run&#8221;. This will then enter either {SYSTEM_PHP} or {SITE_PHP}.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">{SYSTEM_PHP}<\/h3>\n\n\n\n<p>is always the PHP version directly installed on the server. Instead of {SYSTEM_PHP} you can also enter only php in this case. With the link &#8220;[PHP version of the server]&#8221; this version is set.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">{SITE_PHP}<\/h3>\n\n\n\n<p>If you want the cron job to use the same PHP version as your web siet (we provide you with different versions), you can use the link &#8220;[PHP version of the web page]&#8221; {SYSTEM_PHP}. If you later change the PHP version of your website, the start of the cron job will also be changed so that it always runs with the PHP version of your website.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>You can not only use the PHP version of the server for a cron job. Execute PHP Script If you want to execute a PHP&hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-698","post","type-post","status-publish","format-standard","hentry","category-blog"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v23.9 (Yoast SEO v27.3) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>Set PHP version for cronjobs<\/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:\/\/schaal-it.dev\/en\/blog\/set-php-version-for-cronjobs\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Set PHP version for cronjobs\" \/>\n<meta property=\"og:description\" content=\"You can not only use the PHP version of the server for a cron job. Execute PHP Script If you want to execute a PHP&hellip;\" \/>\n<meta property=\"og:url\" content=\"https:\/\/schaal-it.dev\/en\/blog\/set-php-version-for-cronjobs\/\" \/>\n<meta property=\"og:site_name\" content=\"schaal @it UG\" \/>\n<meta property=\"article:published_time\" content=\"2020-11-02T09:22:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-10-22T08:23:44+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/schaal-it.dev\/en\/wp-content\/uploads\/sites\/2\/2023\/10\/cron_de.jpg\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/blog\\\/set-php-version-for-cronjobs\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/blog\\\/set-php-version-for-cronjobs\\\/\"},\"author\":{\"name\":\"admin\",\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/#\\\/schema\\\/person\\\/97112bea38186367c303945fe91f1101\"},\"headline\":\"Set PHP version for cronjobs\",\"datePublished\":\"2020-11-02T09:22:00+00:00\",\"dateModified\":\"2023-10-22T08:23:44+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/blog\\\/set-php-version-for-cronjobs\\\/\"},\"wordCount\":172,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/blog\\\/set-php-version-for-cronjobs\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/wp-content\\\/uploads\\\/sites\\\/2\\\/2023\\\/10\\\/cron_de.jpg\",\"articleSection\":[\"Blog\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/schaal-it.dev\\\/en\\\/blog\\\/set-php-version-for-cronjobs\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/blog\\\/set-php-version-for-cronjobs\\\/\",\"url\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/blog\\\/set-php-version-for-cronjobs\\\/\",\"name\":\"Set PHP version for cronjobs\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/blog\\\/set-php-version-for-cronjobs\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/blog\\\/set-php-version-for-cronjobs\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/wp-content\\\/uploads\\\/sites\\\/2\\\/2023\\\/10\\\/cron_de.jpg\",\"datePublished\":\"2020-11-02T09:22:00+00:00\",\"dateModified\":\"2023-10-22T08:23:44+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/blog\\\/set-php-version-for-cronjobs\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/schaal-it.dev\\\/en\\\/blog\\\/set-php-version-for-cronjobs\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/blog\\\/set-php-version-for-cronjobs\\\/#primaryimage\",\"url\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/wp-content\\\/uploads\\\/sites\\\/2\\\/2023\\\/10\\\/cron_de.jpg\",\"contentUrl\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/wp-content\\\/uploads\\\/sites\\\/2\\\/2023\\\/10\\\/cron_de.jpg\",\"width\":971,\"height\":757},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/blog\\\/set-php-version-for-cronjobs\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Startseite\",\"item\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Set PHP version for cronjobs\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/#website\",\"url\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/\",\"name\":\"schaal @it UG\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/#organization\",\"name\":\"schaal@it UG\",\"url\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/wp-content\\\/uploads\\\/sites\\\/2\\\/2023\\\/10\\\/cropped-schaal_it_logo2_2_-_250px.png\",\"contentUrl\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/wp-content\\\/uploads\\\/sites\\\/2\\\/2023\\\/10\\\/cropped-schaal_it_logo2_2_-_250px.png\",\"width\":250,\"height\":42,\"caption\":\"schaal@it UG\"},\"image\":{\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/#\\\/schema\\\/logo\\\/image\\\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/#\\\/schema\\\/person\\\/97112bea38186367c303945fe91f1101\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/d608e74bb5cd2c03fa61fb269810c56ac375940d126f01ea5954cc0a1336e0dc?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/d608e74bb5cd2c03fa61fb269810c56ac375940d126f01ea5954cc0a1336e0dc?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/d608e74bb5cd2c03fa61fb269810c56ac375940d126f01ea5954cc0a1336e0dc?s=96&d=mm&r=g\",\"caption\":\"admin\"},\"sameAs\":[\"https:\\\/\\\/schaal-it.dev\"],\"url\":\"https:\\\/\\\/schaal-it.dev\\\/en\\\/author\\\/admin\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Set PHP version for cronjobs","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:\/\/schaal-it.dev\/en\/blog\/set-php-version-for-cronjobs\/","og_locale":"en_US","og_type":"article","og_title":"Set PHP version for cronjobs","og_description":"You can not only use the PHP version of the server for a cron job. Execute PHP Script If you want to execute a PHP&hellip;","og_url":"https:\/\/schaal-it.dev\/en\/blog\/set-php-version-for-cronjobs\/","og_site_name":"schaal @it UG","article_published_time":"2020-11-02T09:22:00+00:00","article_modified_time":"2023-10-22T08:23:44+00:00","og_image":[{"url":"https:\/\/schaal-it.dev\/en\/wp-content\/uploads\/sites\/2\/2023\/10\/cron_de.jpg","type":"","width":"","height":""}],"author":"admin","twitter_card":"summary_large_image","twitter_misc":{"Written by":"admin","Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/schaal-it.dev\/en\/blog\/set-php-version-for-cronjobs\/#article","isPartOf":{"@id":"https:\/\/schaal-it.dev\/en\/blog\/set-php-version-for-cronjobs\/"},"author":{"name":"admin","@id":"https:\/\/schaal-it.dev\/en\/#\/schema\/person\/97112bea38186367c303945fe91f1101"},"headline":"Set PHP version for cronjobs","datePublished":"2020-11-02T09:22:00+00:00","dateModified":"2023-10-22T08:23:44+00:00","mainEntityOfPage":{"@id":"https:\/\/schaal-it.dev\/en\/blog\/set-php-version-for-cronjobs\/"},"wordCount":172,"commentCount":0,"publisher":{"@id":"https:\/\/schaal-it.dev\/en\/#organization"},"image":{"@id":"https:\/\/schaal-it.dev\/en\/blog\/set-php-version-for-cronjobs\/#primaryimage"},"thumbnailUrl":"https:\/\/schaal-it.dev\/en\/wp-content\/uploads\/sites\/2\/2023\/10\/cron_de.jpg","articleSection":["Blog"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/schaal-it.dev\/en\/blog\/set-php-version-for-cronjobs\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/schaal-it.dev\/en\/blog\/set-php-version-for-cronjobs\/","url":"https:\/\/schaal-it.dev\/en\/blog\/set-php-version-for-cronjobs\/","name":"Set PHP version for cronjobs","isPartOf":{"@id":"https:\/\/schaal-it.dev\/en\/#website"},"primaryImageOfPage":{"@id":"https:\/\/schaal-it.dev\/en\/blog\/set-php-version-for-cronjobs\/#primaryimage"},"image":{"@id":"https:\/\/schaal-it.dev\/en\/blog\/set-php-version-for-cronjobs\/#primaryimage"},"thumbnailUrl":"https:\/\/schaal-it.dev\/en\/wp-content\/uploads\/sites\/2\/2023\/10\/cron_de.jpg","datePublished":"2020-11-02T09:22:00+00:00","dateModified":"2023-10-22T08:23:44+00:00","breadcrumb":{"@id":"https:\/\/schaal-it.dev\/en\/blog\/set-php-version-for-cronjobs\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/schaal-it.dev\/en\/blog\/set-php-version-for-cronjobs\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/schaal-it.dev\/en\/blog\/set-php-version-for-cronjobs\/#primaryimage","url":"https:\/\/schaal-it.dev\/en\/wp-content\/uploads\/sites\/2\/2023\/10\/cron_de.jpg","contentUrl":"https:\/\/schaal-it.dev\/en\/wp-content\/uploads\/sites\/2\/2023\/10\/cron_de.jpg","width":971,"height":757},{"@type":"BreadcrumbList","@id":"https:\/\/schaal-it.dev\/en\/blog\/set-php-version-for-cronjobs\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Startseite","item":"https:\/\/schaal-it.dev\/en\/"},{"@type":"ListItem","position":2,"name":"Set PHP version for cronjobs"}]},{"@type":"WebSite","@id":"https:\/\/schaal-it.dev\/en\/#website","url":"https:\/\/schaal-it.dev\/en\/","name":"schaal @it UG","description":"","publisher":{"@id":"https:\/\/schaal-it.dev\/en\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/schaal-it.dev\/en\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/schaal-it.dev\/en\/#organization","name":"schaal@it UG","url":"https:\/\/schaal-it.dev\/en\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/schaal-it.dev\/en\/#\/schema\/logo\/image\/","url":"https:\/\/schaal-it.dev\/en\/wp-content\/uploads\/sites\/2\/2023\/10\/cropped-schaal_it_logo2_2_-_250px.png","contentUrl":"https:\/\/schaal-it.dev\/en\/wp-content\/uploads\/sites\/2\/2023\/10\/cropped-schaal_it_logo2_2_-_250px.png","width":250,"height":42,"caption":"schaal@it UG"},"image":{"@id":"https:\/\/schaal-it.dev\/en\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/schaal-it.dev\/en\/#\/schema\/person\/97112bea38186367c303945fe91f1101","name":"admin","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/d608e74bb5cd2c03fa61fb269810c56ac375940d126f01ea5954cc0a1336e0dc?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/d608e74bb5cd2c03fa61fb269810c56ac375940d126f01ea5954cc0a1336e0dc?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/d608e74bb5cd2c03fa61fb269810c56ac375940d126f01ea5954cc0a1336e0dc?s=96&d=mm&r=g","caption":"admin"},"sameAs":["https:\/\/schaal-it.dev"],"url":"https:\/\/schaal-it.dev\/en\/author\/admin\/"}]}},"_links":{"self":[{"href":"https:\/\/schaal-it.dev\/en\/wp-json\/wp\/v2\/posts\/698","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/schaal-it.dev\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/schaal-it.dev\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/schaal-it.dev\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/schaal-it.dev\/en\/wp-json\/wp\/v2\/comments?post=698"}],"version-history":[{"count":1,"href":"https:\/\/schaal-it.dev\/en\/wp-json\/wp\/v2\/posts\/698\/revisions"}],"predecessor-version":[{"id":700,"href":"https:\/\/schaal-it.dev\/en\/wp-json\/wp\/v2\/posts\/698\/revisions\/700"}],"wp:attachment":[{"href":"https:\/\/schaal-it.dev\/en\/wp-json\/wp\/v2\/media?parent=698"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/schaal-it.dev\/en\/wp-json\/wp\/v2\/categories?post=698"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/schaal-it.dev\/en\/wp-json\/wp\/v2\/tags?post=698"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}