ps3z Posted December 4, 2013 Share Posted December 4, 2013 (edited) Hi i modified classes/validation php for allow iframes. but i got blank page problem. i loaded the backup of file. but still getting that error at below. public_html/classes/ObjectModel.php on line 188 Regards Ps3z Edited December 4, 2013 by ps3z (see edit history) Link to comment Share on other sites More sharing options...
El Patron Posted December 4, 2013 Share Posted December 4, 2013 how about a ps version, that is most helpful...maybe someone can send you a 'clean' file or get one by downloading your version and extracting that file for 1.5 there is a setting to allow iframes...so if you are running 1.5 and mange to fix your 'snafu' try this http://screencast.com/t/Gx8s6Z19Q Link to comment Share on other sites More sharing options...
ps3z Posted December 4, 2013 Author Share Posted December 4, 2013 how about a ps version, that is most helpful...maybe someone can send you a 'clean' file or get one by downloading your version and extracting that file for 1.5 there is a setting to allow iframes...so if you are running 1.5 and mange to fix your 'snafu' try this http://screencast.com/t/Gx8s6Z19Q ps version is 1.5.6.1 front and back office disabled Link to comment Share on other sites More sharing options...
ps3z Posted December 4, 2013 Author Share Posted December 4, 2013 i have clean file i got backup before load edited one. i loaded the backup file.but getting problem like this. Link to comment Share on other sites More sharing options...
El Patron Posted December 4, 2013 Share Posted December 4, 2013 here is a 1.5.6.1 classes/Validate.php upload using ftp...to classes/Validate.php Validate.php Link to comment Share on other sites More sharing options...
ps3z Posted December 4, 2013 Author Share Posted December 4, 2013 here is a 1.5.6.1 classes/Validate.php upload using ftp...to classes/Validate.php Validate.php i did upload.result is same. its too weird i didnt touch to anything different Link to comment Share on other sites More sharing options...
El Patron Posted December 4, 2013 Share Posted December 4, 2013 i did upload.result is same. its too weird i didnt touch to anything different turn on errors then and see what the issue is...that is all part of the development cycle Link to comment Share on other sites More sharing options...
ps3z Posted December 4, 2013 Author Share Posted December 4, 2013 turn on errors then and see what the issue is...that is all part of the development cycle i did open debug mode www.worldbazaar.com.tr error is Fatal error: Class 'Validate' not found in /home/worldbaz/public_html/classes/ObjectModel.php on line 188 Link to comment Share on other sites More sharing options...
El Patron Posted December 4, 2013 Share Posted December 4, 2013 it would seem that you do not have classes/Validate.php, or you have a bad copy of it... are you using ftp? I know some people have problems with their ftp not honoring upper case, i.e. Validate.php not validate.php Link to comment Share on other sites More sharing options...
ps3z Posted December 4, 2013 Author Share Posted December 4, 2013 it would seem that you do not have classes/Validate.php, or you have a bad copy of it... are you using ftp? I know some people have problems with their ftp not honoring upper case, i.e. Validate.php not validate.php yes im using filezilla. and Validation.php upper cased Link to comment Share on other sites More sharing options...
El Patron Posted December 4, 2013 Share Posted December 4, 2013 boy...that is weird...I mean I've probably done this...but I have walked you through what I think should have fixed it... download the Validate.php code you have on your remote server and attach it to this post, click 'more reply options' to attach. hurry..my mom is calling me for dinner...jajajaja Link to comment Share on other sites More sharing options...
ps3z Posted December 4, 2013 Author Share Posted December 4, 2013 validation file Validate.php Link to comment Share on other sites More sharing options...
El Patron Posted December 4, 2013 Share Posted December 4, 2013 looks purrrfect... and you placed and 'also' see this file in folder classes yes? Link to comment Share on other sites More sharing options...
ps3z Posted December 4, 2013 Author Share Posted December 4, 2013 looks purrrfect... and you placed and 'also' see this file in folder classes yes? yes ofcourse. i seeing it already Link to comment Share on other sites More sharing options...
ps3z Posted December 4, 2013 Author Share Posted December 4, 2013 i checked that line of 188 on objectmodel.php if (!Validate::isTableOrIdentifier($this->def['primary']) || !Validate::isTableOrIdentifier($this->def['table'])) Link to comment Share on other sites More sharing options...
El Patron Posted December 4, 2013 Share Posted December 4, 2013 email me, see my signature below, I will need ftp access I am leaving the office and can take a look at this from home... Link to comment Share on other sites More sharing options...
ps3z Posted December 4, 2013 Author Share Posted December 4, 2013 email me, see my signature below, I will need ftp access I am leaving the office and can take a look at this from home... its working back by itself. i dont know what happend. Link to comment Share on other sites More sharing options...
vekia Posted December 4, 2013 Share Posted December 4, 2013 regenereate cache/class_index.php will work then. and regarding to this problem: you used wrong code, i suppose that you used isCleanHtml without second param Link to comment Share on other sites More sharing options...
ps3z Posted December 4, 2013 Author Share Posted December 4, 2013 Thanks for your helps.if will happen something..i will type you. have a nice dinner Link to comment Share on other sites More sharing options...
vekia Posted December 4, 2013 Share Posted December 4, 2013 public static function isCleanHtml($html, $allow_iframe = false){ return $html; } modifiaiton will work then Link to comment Share on other sites More sharing options...
ps3z Posted December 4, 2013 Author Share Posted December 4, 2013 public static function isCleanHtml($html, $allow_iframe = false){ return $html; } modifiaiton will work then your codes will work if enabled Allow iframes on html fields ? bcz when i did enable it. its not allowing me to add youtube videos Link to comment Share on other sites More sharing options...
vekia Posted December 4, 2013 Share Posted December 4, 2013 my mistake! there should be return 'true'; Link to comment Share on other sites More sharing options...
ps3z Posted December 4, 2013 Author Share Posted December 4, 2013 (edited) my mistake! there should be return 'true'; when i allow the iframe on back office. website ssl is insecure. so i would to make it secured and would to share products videos etc. so your solution for it? i would to know it. Edited December 4, 2013 by ps3z (see edit history) Link to comment Share on other sites More sharing options...
vekia Posted December 4, 2013 Share Posted December 4, 2013 product pages aren't with ssl, only when you select option to force ssl on all pages, you selected this option? Link to comment Share on other sites More sharing options...
El Patron Posted December 5, 2013 Share Posted December 5, 2013 regenereate cache/class_index.php will work then. and regarding to this problem: you used wrong code, i suppose that you used isCleanHtml without second param howdy milos, I thought of this but I thought it was only for overrides!...thanks for helping out... Link to comment Share on other sites More sharing options...
vekia Posted December 5, 2013 Share Posted December 5, 2013 howdy milos, I thought of this but I thought it was only for overrides!...thanks for helping out... I've noticed when some class doesn't work (for example: I changed something in Validate class I forgot about semicolon, bracket etc. Effect: Validate class is crashed) then after recompilation class_index.php hasn't got line with information about crashed Validate class, so even if we upload working class, it will not be loaded due to the fact that in class_index.php there is no information about it I discovered it two days ago Link to comment Share on other sites More sharing options...
ps3z Posted December 5, 2013 Author Share Posted December 5, 2013 product pages aren't with ssl, only when you select option to force ssl on all pages, you selected this option? i mentioned description is not allowing me to add youtube videos if i disable iframe on back office. http://screencast.com/t/j0W8jHKul0F Link to comment Share on other sites More sharing options...
Juanki_222 Posted February 4, 2014 Share Posted February 4, 2014 (edited) Hello prestashopers,I have the same problem than @ps3z He says that the problem is solved by itself?I uploaded the Validation.php that you uploaded El Patron, but still that msg:Fatal error: Class 'Validate' not found in /homepages/46/d507973978/htdocs/classes/ObjectModel.php on line 188I have the same version too,thanks. EDIT: Have cleaned the cache too. Edited February 4, 2014 by Juanki_222 (see edit history) Link to comment Share on other sites More sharing options...
El Patron Posted February 4, 2014 Share Posted February 4, 2014 Hello prestashopers, I have the same problem than @ps3z He says that the problem is solved by itself? I uploaded the Validation.php that you uploaded El Patron, but still that msg: Fatal error: Class 'Validate' not found in /homepages/46/d507973978/htdocs/classes/ObjectModel.php on line 188 I have the same version too, thanks. EDIT: Have cleaned the cache too. try this, delete the following file using ftp or your hosting control panel cache/class_index.php 1 Link to comment Share on other sites More sharing options...
Juanki_222 Posted February 4, 2014 Share Posted February 4, 2014 Yeaaaaaah!!! Now is working, thanks a lot El Patron This file is the main cache of the site?? For modifications in future... Link to comment Share on other sites More sharing options...
El Patron Posted February 4, 2014 Share Posted February 4, 2014 Yeaaaaaah!!! Now is working, thanks a lot El Patron This file is the main cache of the site?? For modifications in future... it is the main cache for classes...even if you had not deleted it over time it would have rebuilt itself. happy prestashopping Link to comment Share on other sites More sharing options...
umutsun Posted June 2, 2015 Share Posted June 2, 2015 Hi I have very common problem; Fatal error: Call to undefined method Validate::isTableOrIdentifier() in /var/www/vhosts/biguzellikyapsana.com/httpdocs/classes/ObjectModel.php on line 191 Line says: if (!Validate::isTableOrIdentifier($this->def['primary']) || !Validate::isTableOrIdentifier($this->def['table'])) my website works probebly except this module when it is in Turkish: https://www.biguzellikyapsana.com/modules/facebookpsshoptab/ in English version it works fine. Module developer told that issue was related with Prestashop because they tested on other Turkish(or another) langauge setting. So we have some similarities could you suggest something please? Link to comment Share on other sites More sharing options...
vekia Posted June 2, 2015 Share Posted June 2, 2015 open: classes/Validate.php does this file contains function isTableOrIdentifier() ? Link to comment Share on other sites More sharing options...
Humanoid Posted September 1, 2015 Share Posted September 1, 2015 (edited) After upgrade to PrestaShop™ 1.5.6.3 I can't do any changes to catalog/products. Always get the error: The description field (English (English)) is invalid. The description field (Finnish) is invalid. The short_description field (English (English)) is invalid. The short_description field (Finnish) is invalid. Can I have clear help, step by step for this problem? Trying to change this Validate.php file, but nothing happening. I'm not sure I did it right, so I return to backup file. Allow iframes on html fields is ON. Deleting class_index.php - no changes. Disabeling product produces error: Property Product->description is not valid What do I missing? ----------- Ok I did it, and it seems to be working. I change Validate.php public static function isCleanHtml($html, $allow_iframe = false) { $events = 'onmousedown|onmousemove|onmmouseup|onmouseover|onmouseout|onload|onunload|onfocus|onblur|onchange'; $events .= '|onsubmit|ondblclick|onclick|onkeydown|onkeyup|onkeypress|onmouseenter|onmouseleave|onerror|onselect|onreset|onabort|ondragdrop|onresize|onactivate|onafterprint|onmoveend'; $events .= '|onafterupdate|onbeforeactivate|onbeforecopy|onbeforecut|onbeforedeactivate|onbeforeeditfocus|onbeforepaste|onbeforeprint|onbeforeunload|onbeforeupdate|onmove'; $events .= '|onbounce|oncellchange|oncontextmenu|oncontrolselect|oncopy|oncut|ondataavailable|ondatasetchanged|ondatasetcomplete|ondeactivate|ondrag|ondragend|ondragenter|onmousewheel'; $events .= '|ondragleave|ondragover|ondragstart|ondrop|onerrorupdate|onfilterchange|onfinish|onfocusin|onfocusout|onhashchange|onhelp|oninput|onlosecapture|onmessage|onmouseup|onmovestart'; $events .= '|onoffline|ononline|onpaste|onpropertychange|onreadystatechange|onresizeend|onresizestart|onrowenter|onrowexit|onrowsdelete|onrowsinserted|onscroll|onsearch|onselectionchange'; $events .= '|onselectstart|onstart|onstop'; if (preg_match('/<[\s]*script/ims', $html) || preg_match('/('.$events.')[\s]*=/ims', $html) || preg_match('/.*script\:/ims', $html)) return false; if (!$allow_iframe && preg_match('/<[\s]*(i?frame|form|input|embed|object)/ims', $html)) return false; return true; } -------- TO: -------- public static function isCleanHtml($html, $allow_iframe = false){ return true;/* $events = 'onmousedown|onmousemove|onmmouseup|onmouseover|onmouseout|onload|onunload|onfocus|onblur|onchange'; $events .= '|onsubmit|ondblclick|onclick|onkeydown|onkeyup|onkeypress|onmouseenter|onmouseleave|onerror|onselect|onreset|onabort|ondragdrop|onresize|onactivate|onafterprint|onmoveend'; $events .= '|onafterupdate|onbeforeactivate|onbeforecopy|onbeforecut|onbeforedeactivate|onbeforeeditfocus|onbeforepaste|onbeforeprint|onbeforeunload|onbeforeupdate|onmove'; $events .= '|onbounce|oncellchange|oncontextmenu|oncontrolselect|oncopy|oncut|ondataavailable|ondatasetchanged|ondatasetcomplete|ondeactivate|ondrag|ondragend|ondragenter|onmousewheel'; $events .= '|ondragleave|ondragover|ondragstart|ondrop|onerrorupdate|onfilterchange|onfinish|onfocusin|onfocusout|onhashchange|onhelp|oninput|onlosecapture|onmessage|onmouseup|onmovestart'; $events .= '|onoffline|ononline|onpaste|onpropertychange|onreadystatechange|onresizeend|onresizestart|onrowenter|onrowexit|onrowsdelete|onrowsinserted|onscroll|onsearch|onselectionchange'; $events .= '|onselectstart|onstart|onstop'; return (!preg_match('/<[ \t\n]*script/ims', $html) && !preg_match('/('.$events.')[ \t\n]*=/ims', $html) && !preg_match('/.*script\:/ims', $html));*/return $html; } Edited September 2, 2015 by Humanoid (see edit history) Link to comment Share on other sites More sharing options...
Recommended Posts