GloryHorse Posted November 10, 2009 Share Posted November 10, 2009 We use Bitrix for our website and I think I deleted an php end tag by accident and I can't spot the mistake. The project.php used to look like this google cached copy (pictures along the side): http://74.125.95.132/search?q=cache:CjHQ0Io-ok4J:www.hudsondesign.biz/professional-services/project.php%3FSID%3D4%26ID%3D8+http://www.hudsondesign.biz/professional-services/project.php&cd=2&hl=en&ct=clnk&gl=us Now it looks like this... http://www.hudsondesign.biz/professional-services/project.php?SID=4&ID=8 Is is ok to post the code for project.php so someone can help me find the missing tag? Quote Link to comment https://forums.phpfreaks.com/topic/181037-i-think-this-is-a-simple-fix-but-i-cant-find-it/ Share on other sites More sharing options...
Kaboom Posted November 10, 2009 Share Posted November 10, 2009 I know this isn't really a helpful hint but try taking the image scroler code on the side from the homepage because it's working there, then add it to those pages? Quote Link to comment https://forums.phpfreaks.com/topic/181037-i-think-this-is-a-simple-fix-but-i-cant-find-it/#findComment-955190 Share on other sites More sharing options...
mikesta707 Posted November 10, 2009 Share Posted November 10, 2009 I see no difference... post the code maybe Quote Link to comment https://forums.phpfreaks.com/topic/181037-i-think-this-is-a-simple-fix-but-i-cant-find-it/#findComment-955197 Share on other sites More sharing options...
GloryHorse Posted November 10, 2009 Author Share Posted November 10, 2009 <? require($_SERVER["DOCUMENT_ROOT"]."/bitrix/header.php"); $APPLICATION->SetTitle(""); ?><? IncludeAjax(); $ID = intval($_REQUEST["ID"]); $SID = intval($_REQUEST["SID"]); $obSection = CIBlockSection::GetList(Array("SORT" => "ASC"), Array("IBLOCK_ID" => 1, "ID" => $SID)); if($arSection = $obSection->Fetch()) { $arResult = Array(); $arResult["SECTION"] = $arSection; $obElement = CIBlockElement::GetList(Array("SORT" => "ASC"), Array("IBLOCK_ID" => 1, "SECTION_ID" => $SID, "ID" => $ID, "ACTIVE" => "Y")); if($arElement = $obElement->GetNextElement()) { $arFields = $arElement->GetFields(); $arProps = $arElement->GetProperties(); $APPLICATION->SetTitle($arFields["NAME"]); foreach($arProps["LARGE_IMAGES"]["VALUE"] as $iImg) { if($iImg > 0) { $arProps["LARGE_IMAGES_PATH"]["VALUE"][] = CFile::GetPath($iImg); } } foreach($arProps["SMALL_IMAGES"]["VALUE"] as $iImg) { if($iImg > 0) { $arProps["SMALL_IMAGES_PATH"]["VALUE"][] = CFile::GetPath($iImg); } } $arResult["ELEMENT"] = Array( "FIELDS" => $arFields, "PROPS" => $arProps, ); } } //echo "<pre>"; print_r($arResult); die(); ?> <?if(is_array($arResult)):?> <div class="photo_block_full"> <div class="right_column_photo"> <div class="photo_column_header"><?=$arResult["ELEMENT"]["FIELDS"]["NAME"]?></div> <?if(is_array($arResult["ELEMENT"]["PROPS"]["SMALL_IMAGES_PATH"]["VALUE"]) && count($arResult["ELEMENT"]["PROPS"]["SMALL_IMAGES_PATH"]["VALUE"]) > 3):?> <div class="red_arrow_up" onclick="rotateUp();return false;"></div> <?endif;?> <!--photo tape inner --> <div class="photo_overflow_int"> <div class="photos_tape_full"> <div style="font-size: 1px;" id="photoShow1"></div> <div style="font-size: 1px;" id="photoShow2"></div> <div style="font-size: 1px;" id="photoShow3"></div> <?if(is_array($arResult["ELEMENT"]["PROPS"]["SMALL_IMAGES_PATH"]["VALUE"]) && count($arResult["ELEMENT"]["PROPS"]["SMALL_IMAGES_PATH"]["VALUE"]) > 0):?> <? $i = 0; foreach($arResult["ELEMENT"]["PROPS"]["SMALL_IMAGES_PATH"]["VALUE"] as $sImgPath): $i++; ?> <?=$i?> <?endforeach;?> <input type="hidden" value="1" id="photoRotateCounter" name="photoRotateCounter" /> <?=count($arResult["ELEMENT"]["PROPS"]["SMALL_IMAGES_PATH"]["VALUE"])?> <input type="hidden" value="3" id="photoRotateLength" name="photoRotateLength" /> <?endif;?> </div> </div> <?if(is_array($arResult["ELEMENT"]["PROPS"]["SMALL_IMAGES_PATH"]["VALUE"]) && count($arResult["ELEMENT"]["PROPS"]["SMALL_IMAGES_PATH"]["VALUE"]) > 3):?> <div class="red_arrow_down" onclick="rotateDown();return false;"></div> <?endif;?> <div class="int_back_block"><?=$SID?></div> </div> <div class="large_photo_block"> <?if(strlen($arResult["ELEMENT"]["PROPS"]["LARGE_IMAGES_PATH"]["VALUE"][0]) > 0):?> <img src="<?=$arResult["ELEMENT"]["PROPS"]["LARGE_IMAGES_PATH"]["VALUE"][0]?>" id="large_photo" /> <?endif;?> </div> </div> <div class="content_full"> <div class="right_text_block"> <a href="/contact-us/information/"><img title="Hudson Design" alt="Hudson Design" class="bottom_logo" src="/images/bottom_logo.gif" /></a> <div class="abs_more"> <a class="via_email_links" href="/contact-us/">via e-mail <img class="mail_pic" src="/images/mail_pic.gif" /></a> </div> </div> <div class="left_content_block"> <div class="text_block_text"> <span class="content_header"><?=$arResult["ELEMENT"]["FIELDS"]["NAME"]?></span><?if(strlen($arResult["ELEMENT"]["FIELDS"]["DETAIL_TEXT"]) > 900):?> <!--graohic scroll--> <div class="content_scroll_block"> <div onmouseout="this.className='scroll_up';return false;" onmouseover="this.className='scroll_up_on';return false;" class="scroll_up" onclick="scroll_up('scroll');" id="scroll_up"></div> <div onmouseout="this.className='scroll_down';return false;" onmouseover="this.className='scroll_down_on';return false;" class="scroll_down" onclick="scroll_down('scroll');" id="scroll_down"></div> </div> <!--graohic scroll--> <?endif;?> <div id="scroll" class="content_overflow"> <?=$arResult["ELEMENT"]["FIELDS"]["DETAIL_TEXT"]?> </div> </div> </div> </div> <?if(is_array($arResult["ELEMENT"]["PROPS"]["SMALL_IMAGES_PATH"]["VALUE"]) && count($arResult["ELEMENT"]["PROPS"]["SMALL_IMAGES_PATH"]["VALUE"]) > 0):?> <script type="text/javascript"> <img src="/bitrix/images/fileman/htmledit2/php.gif" border="0" __bxtagname="php" __bxcontainer="{'code': '<?\r\n $i = 0;\r\n foreach($arResult["ELEMENT"]["PROPS"]["SMALL_IMAGES_PATH"]["VALUE"] as $arElement):\r\n $i++;\r\n if($i > 3)\r\n break;\r\n ?>'}" /> document.getElementById("photoShow<img src="/bitrix/images/fileman/htmledit2/php.gif" border="0" __bxtagname="php" __bxcontainer="{'code': '<?=$i?>'}" />").innerHTML = document.getElementById("photoHid<img src="/bitrix/images/fileman/htmledit2/php.gif" border="0" __bxtagname="php" __bxcontainer="{'code': '<?=$i?>'}" />").innerHTML; <img src="/bitrix/images/fileman/htmledit2/php.gif" border="0" __bxtagname="php" __bxcontainer="{'code': '<?endforeach;?>'}" /> </script> <?endif;?> <?endif;?> <input type="hidden" value="1" id="curSel" name="curSel" /><?require($_SERVER["DOCUMENT_ROOT"]."/bitrix/footer.php");?> Quote Link to comment https://forums.phpfreaks.com/topic/181037-i-think-this-is-a-simple-fix-but-i-cant-find-it/#findComment-955200 Share on other sites More sharing options...
mikesta707 Posted November 10, 2009 Share Posted November 10, 2009 I can't see much wrong. it looks like you have an extra endif at the end of the page (maybe, but maybe not). I didn't really even see anythign wrong with the links... they looked exactly the same. What is the problem you are having exactly? Quote Link to comment https://forums.phpfreaks.com/topic/181037-i-think-this-is-a-simple-fix-but-i-cant-find-it/#findComment-955203 Share on other sites More sharing options...
GloryHorse Posted November 10, 2009 Author Share Posted November 10, 2009 The page is supposed to show a series of thumbnails on the right hand column that are clickable. My first link shows the google cache copy which has the thumbnails. The second link has the current live version that has lost the thumbnails. I was editing this part of the page in Bitrix: Williams Overlooking Central Park, this sprawling Upper West Side apartment serves as the East Coast base for a busy theatrical couple and their two children. The living room motif began with the premise that this most public of all spaces in the home should feel as if in perpetual sunrise. I may have accidentially erased some PHP code. It's the only part of the page I touched. Quote Link to comment https://forums.phpfreaks.com/topic/181037-i-think-this-is-a-simple-fix-but-i-cant-find-it/#findComment-955214 Share on other sites More sharing options...
mikesta707 Posted November 10, 2009 Share Posted November 10, 2009 can you post the lines that was around. can't seem to find it Quote Link to comment https://forums.phpfreaks.com/topic/181037-i-think-this-is-a-simple-fix-but-i-cant-find-it/#findComment-955224 Share on other sites More sharing options...
GloryHorse Posted November 10, 2009 Author Share Posted November 10, 2009 I think it was near this: <?=$arResult["ELEMENT"]["FIELDS"]["NAME"]?> In Bitrix you only see a yellow block that says php. When I asked for the properties of the block near where I was editing, that is the result it gave me. Quote Link to comment https://forums.phpfreaks.com/topic/181037-i-think-this-is-a-simple-fix-but-i-cant-find-it/#findComment-955227 Share on other sites More sharing options...
mikesta707 Posted November 10, 2009 Share Posted November 10, 2009 and your not getting any errors? do you have error reporting set to E_ALL? one thing if($arSection = $obSection->Fetch()) { are you sure it should be = and not ==? i'd assume with a fetch() method, it should be just =, but im not sure Quote Link to comment https://forums.phpfreaks.com/topic/181037-i-think-this-is-a-simple-fix-but-i-cant-find-it/#findComment-955241 Share on other sites More sharing options...
GloryHorse Posted November 10, 2009 Author Share Posted November 10, 2009 I tried changing it and got this error Parse error: syntax error, unexpected '?' in /home7/hudsond1/public_html/professional-services/project2.php on line 9 Quote Link to comment https://forums.phpfreaks.com/topic/181037-i-think-this-is-a-simple-fix-but-i-cant-find-it/#findComment-955282 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.