Jump to content

convict

Member
  • Posts

    1,302
  • Joined

  • Last visited

  • Days Won

    1

Posts posted by convict

  1. OMG, little bit better however <php? does your code 'incurable' B) , IF condition SYNTAX ERROR and useless. Look at this

    <?
    
    include_once("includes/global.inc.php");
    
    
    
    session_start();
    
    
    
    include_once("classes/db.inc.php");
    
    
    
    $db = new db();
    
    include_once("includes/functions.inc.php");
    
    $config = fetchDbConfig("config");
    
    
    
    include_once("includes/sslSwitch.inc.php");
    
    
    
    include_once("includes/session.inc.php");
    
    
    
    if($ccUserData[0]['customer_id']>0){
    
    	echo "i am logged in";
    
    } else {
    
    	echo "i am NOT logged in";
    
    }
    
    ?>

    I think that next steps are completely clear :)

    Regards

  2. Session timeout in progress. Check value of session.gc_maxlifetime in php.ini (or CC3 Admin panel - Server info ). Deafault setting is 1440 (1440 seconds -> 24 mins).

    Session.gc_maxlifetime specifies the number of seconds after which data will be seen as 'garbage' and cleaned up. :)

    Search and set desidered value up in php.ini (This makes a MASTER value for every PHP script), or place this code in file admin/include/auth.inc BEFORE session_start();

    @ini_set('session.gc_maxlifetime', '3600');

    3600 -> 1 hour (This makes a LOCAL value for CC admin ONLY).

    Be careful, do not set up a huge value because of security B)

  3. Is it possible to put the Site Documents in a box? if so could you show me how please?

    Site Docs are boxed :rolly: , but do you want to place site docs on right or left side? Some templates modificaton is required. It depends on your prefered skin.

    Target files:

    1. skins/[skin name]/styleTemplates/global/index.tpl

    2. skins/[skin name]/styleTemplates/boxes/siteDocs.tpl

    ---------

    Backup your files!

    Skin Killer:

    1.

    open file and move {SITE_DOCS}:

    to section of <div class="colLeft"> tags (left side)

    to section of <div class="colRight"> tags (right side)

    In previous {SITE_DOCS} locality put:

    <div class="siteDocs">
    
    <div class="siteDocsBgRight">
    
    <span class="siteDocsBgLeft">&nbsp;</span> 
    
    </div>
    
    </div>
    
    
    
    
    2. file siteDocs.tpl can be (right sided):
    
    
    
    <!-- BEGIN: site_docs -->
    
    <div class="boxTitleRight">&nbsp;</div>
    
    <div class="boxContentRight">
    
    	<!-- BEGIN: a -->
    
    	<a class="txtSession" href="index.php?act=viewDoc&amp;docId={DATA.doc_id}" class="txtDefault">{DATA.doc_name}</a><br />
    
    	<!-- END: a -->
    
    </div>
    
    <div class="boxFootLeft">&nbsp;</div>
    
    <!-- END: site_docs -->
    
    
    
    
    If you want a Tiltle box, in file includes/boxes/siteDocs.inc.php paste
    
    
    
    $box_content->assign("LANG_SITE_DOCS_TITLE",$lang['admin']['docs']['site_docs']);
     after 
    
    $box_content = new XTemplate ("skins/".$config['skinDir']."/styleTemplates/boxes/siteDocs.tpl");

    AND in file siteDosc.tpl replace &nbsp; in <div class="boxTitleRight">&nbsp;</div> with {LANG_SITE_DOCS_TITLE}.

    Other skins? Little be diferent code :P

  4. Hi Marcel, i am affraid, i did not labour about taxes and shiping. Later.

    Question about upgrading 3.0.0->3.0.1 - read 'Upgrade from 3.0.0 to 3.0.1.txt' from CubeCart 3.0.1 package ;) but at first backup 3 files (removing boxes) mentioned above.

    After all, upload 3 mentioned files above back to site (rewrite).

    Things, we have made (removing boxes) will be well-preserved.

    Milos

  5. It's clear - definitely bad $GLOBALS['rootDir'] value.

    Look at phpinfo.

    Log in as admin user to CC admin panel. Retype URL in your browser, he must ended like this ... admin/misc/info.php an push <ENTER>.

    Or type your own php file and upload it to main shop folder

    <?php
    
     phpinfo();
    
    ?>

    Search for SCRIPT_FILENAME in window with infos about PHP Version. This is wanted absolte path...just copy a part of them..it must ended with shop folder.

    Like this: /any/system/folder/html/shop (shop is name where your shop resides)...

    Maybe this helps finally ;)

  6. Really? B)

    don't use default language therefor but add admin_lang field to database and setup another admin_lang folder... also needs to implement admin_lang control field in admin area.

    You are absolutely right. No issue about. :) But what i told is here more in detail...

    $config = fetchDbConfig("config");
    
    include_once("../../language/".$config['defaultLang']."/lang.inc.php");

    It must be changed (about 70 files). ;)

    Have you any other effective method to obtain an admin_lang value from DB in accordance with

    like this there is no need to touch the existing code
    ?? :(
  7. If any CC Admin, which is NOT Super user has Read only permisions to any section, he can do everything in that section - Delete, Add, Modify.

    My question to CC team: Objective permisions rules will be applicable in the future ever?

    Nowadays, it's policy of trust only ;)

    Milos

  8. I mean the one under Filiaal Amsterdam  :(

    vrakas look at template styleTemplates/global/index.tpl under your prefered skin folder, open it and moodify....

    If you like to add your image, add code below after {INFORMATION}, or write your own box template and other necessary files. But code which you're searching, is easy.

    You can apply some cc3 styles.

    <div class="boxTitleLeft">Your head-line</div>
    
    <div class="boxContentLeft">
    
    <img src="http://www.yoursite.com/anypath.gif" width="xx" height="xx"  border="0" >
    
    </div>
    
    <div class="boxFootLeft">&nbsp;</div>

    Replace www.yoursite.com/anypath.gif with a real one (JPEG, GIF..), type correct width (atention, limited value) and height of image. Type your box headline

    BTW this is done for single language site, because of box head line - Your head-line

    Wanna more details or explanations? ;)

  9. <?php include("includes/navigation.inc.php"); ?> - RELATIVE PATH to file

    <?php include($GLOBALS['rootDir']."/admin/includes/navigation.inc.php"); ?> - ABSOLUTE PATH to file (expected value)

    With your setting nav bar appears accessing php files in admin folder (NOT in subfolders). Any admin subfolder has NOT includes subfolder.

    BTW value of $glob['rootDir'] in includes/global.inc.php is correct?

×
×
  • Create New...