User Profile

Collapse

Profile Sidebar

Collapse
secmazec
secmazec
Last Activity: May 1 '11, 06:40 PM
Joined: Mar 19 '09
Location: Czechia
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • secmazec
    replied to IE7 fix
    Thanks mate, you're a big help as usual. Prolly the only solution, yeh......
    See more | Go to post

    Leave a comment:


  • secmazec
    replied to IE7 fix
    I think I have explained the problem pretty well, instead of fixing bad words you should read it :)

    EDIT:
    Ok, I'll try to explain it from other point of view.

    Tables in all browsers load one by one, inside. And loading is smooth.
    Tables in IE7 and older preload in memmory, and if there's 20 or more pictures (or size > something) it lags for few seconds to like tens of seconds. Very annoying.
    ...
    See more | Go to post

    Leave a comment:


  • secmazec
    started a topic IE7 fix

    IE7 fix

    Hello, I've made a cool website in tables and it put it to centered div. It looks rly amazing, but the tables load s*** in Explorer, so I'm about to rebuild the main structure to DIVs.

    I have one question. How to solve the problem with explorer f***ing up all the padding tags, switches or wtf creates some own with same names like others have normal. Talking about DIV tag.

    Can someone, please, explain me how to control padding...
    See more | Go to post
    Last edited by acoder; Apr 21 '09, 03:10 PM. Reason: Cleaned secmazec's mouth with soap

  • Thanks Ciary, now I understand.
    See more | Go to post

    Leave a comment:


  • I could also use this code for thumbnails on my Website. Big thanks to whoever can and will code it in shortest possible form. :-)
    See more | Go to post

    Leave a comment:


  • secmazec
    replied to session works only in IE not in firefox
    in PHP
    Don't fix what is not broken, please. I respect your oppinion and would be nice to see the same.

    PHP is not exact language and there are always many ways to do some things. That's why I love it and I can programme in my own style.
    See more | Go to post

    Leave a comment:


  • secmazec
    replied to session works only in IE not in firefox
    in PHP
    Oh and I've forgotten, don't forget ! :)

    To put session_start() ; on top of each page, or @session_start( ); to semi-include pages, to suppress exit; or die;
    See more | Go to post

    Leave a comment:


  • secmazec
    replied to session works only in IE not in firefox
    in PHP
    Guys, unfortunately I can't see any problem in any code in here.

    Also talking about cookies is irrelevant, I don't see any command working with it.

    Fix your browser or replace invalid user :)

    No offense, good mood ;)

    You can simply test if your session works with this little code:
    Code:
    <?
    session_start();
    $_SESSION['tester'] = 1;
    if(!$_SESSION['tester'])
    ...
    See more | Go to post

    Leave a comment:


  • secmazec
    replied to explode the / variable
    in PHP
    I have 2 ideas what can cause it.

    1. you don't assign explode into variable, namely array
    Code:
    $path="root/sample";
    $dirs = explode( "/", $path);
    // $dirs[0] = "root", $dirs[1] = "sample";

    2. Your separator is a special character, you need to comment it with backslash
    Code:
    $dirs = explode( "\\", $path);
    See more | Go to post

    Leave a comment:


  • secmazec
    replied to Multiple users login & password
    in PHP
    Nice to hear some positive feedback. I started to realise that I can master the language only by sharing the knowledge and expanding it to fields I don't use for commercial uses.

    So, please, be my guest and post another problem :)

    But my heart is warm today and I want to share, so here's how a model logout.php should look like:
    Code:
    <?
     @session_start(); // @ works without problem, I had some when
    ...
    See more | Go to post

    Leave a comment:


  • secmazec
    replied to Multiple users login & password
    in PHP
    Thank you VM, Dormilich.
    See more | Go to post

    Leave a comment:


  • secmazec
    replied to Multiple users login & password
    in PHP
    I'm sorry, I disagree since I often use them in sql requests in one string, accepted by class function, so any quotes that don't have to be there are helpful in the speed I can create.



    Can you explain more, I have learned PHP all myself from net mostly, so I don't understand meaning "hash value", even I think I have a good idea....
    See more | Go to post

    Leave a comment:


  • secmazec
    replied to Multiple users login & password
    in PHP
    You are on the right way. PHP is the best language for sessions and database access. All you need to do is create 1 database table with at least 2 columns (name and password). But I recommend at least 3, id at every table is very handy in long run or even better 4, for different user access rights.

    Key parts of the code will look like something like this.

    Code:
    <?
    @session_start();
    
    //And store
    ...
    See more | Go to post

    Leave a comment:


  • secmazec
    replied to Easiest shopping cart to develop
    in PHP
    The main idea of the easiest "php" shopping cart to develop. Maybe someone else clicked on this topic hoping to solve this problem.

    But prolly won't help you mate, sorry.
    See more | Go to post

    Leave a comment:


  • secmazec
    replied to Easiest shopping cart to develop
    in PHP
    Code:
    // on top of each page:
    @session_start();
    
    // somewhere in cart.php or so
    
    $_SESSION["basket"] = "product1*price1||product2*price2"; // don't type this :)
    
    $product_array = explode("||",$_SESSION["basket"]);
    
    $i = -1;
    while($product_array[++$i])
         list($name[$i], $price[$i])=explode("*", $product_array[$i]);
    ...
    See more | Go to post

    Leave a comment:


  • I think understanding of .doc structure is the key in here. Maybe you can google it thanks to OpenOffice, but I somehow doubt it (Microsoft protection).

    Also I'd not recommend saving anything like web page in .doc document (like mark, copy and paste) since reverse conversion is very hard (Word ommits tags and creates ridiculous and useless ones).

    I think I'll better explain on example:

    If in HTML you say:...
    See more | Go to post

    Leave a comment:


  • secmazec
    replied to blank lines while writing records in txt file
    in PHP
    Also can't help you if you ask so vague, but I'll at least try and guess it. It might to do something with:
    Code:
    \r\n or \n\r // not 100% sure it's the first one
    \n
    
    // sometimes u need to doubleslash
    \\n\\r or \\r\\n
    \\n
    See more | Go to post
    Last edited by Markus; Mar 20 '09, 04:47 PM. Reason: Please don't be rude.

    Leave a comment:


  • secmazec
    replied to Select All Checkbox
    in PHP
    actually if you only need it in PHP, that's very easy:

    Code:
    $selected = array ('a', 'b', 'c'); // list of selected ids
    
    echo "<input type=\"checkbox\" ";
    
    if($id==$selected)
    echo "checked "; // the magic :p
    
    echo "value=\"$val\" name=\"$id\" id=\"$id\" />";
    N'joy

    PS: JavaScript...
    See more | Go to post

    Leave a comment:


  • secmazec
    replied to Select All Checkbox
    in PHP
    It would be much easier for all if you either describe your problem better or paste some code.

    First name checkboxes logically from 1...N, so you can go trough all of them easily, something like this, and store how many you have in PHP ($cb_sum in my example):
    Code:
    <input type="checkbox" name="option_1" value="Milk"> Milk<br>
    <input type="checkbox" name="option_2"
    ...
    See more | Go to post

    Leave a comment:


  • Hello, this is the code I use on my sites atm. It is ready to use the Firefox bookmark function when Mozilla fixes it. (just comment alert line and uncomment one above when they do so):

    Code:
    <script type="text/javascript"><!--
    // All browser bookmark script
    function bookmarksite(title,url){
    if (window.sidebar) // firefox
    	//window.sidebar.addPanel(title, url, ""); Dont use
    ...
    See more | Go to post

    Leave a comment:

No activity results to display
Show More
Working...