SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    Non-Member hyperimage's Avatar
    Join Date
    Dec 2003
    Location
    Croatia
    Posts
    259
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    addition function or script help

    hello!
    is there a way to make this correctly with some php script:
    Code:
    $x = '2';
    $y = '3';
    $z = $x + $y;
    i tryed in many ways but i stuck every time!
    also i search for this in php.net and nothing again under "plus" or "addition"!
    any help will be appreciated!
    thanx in advance!
    sven

  2. #2
    Sell crazy someplace else markl999's Avatar
    Join Date
    Aug 2003
    Location
    Manchester, UK
    Posts
    4,007
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    PHP Code:
    <?php
    $x 
    '2';
    $y '3';
    $z $x $y;
    echo 
    $z//echo's 5
    $z $x.$y;
    echo 
    $z//echo's 23
    ?>
    Take your pick!!!!!!

  3. #3
    Non-Member hyperimage's Avatar
    Join Date
    Dec 2003
    Location
    Croatia
    Posts
    259
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    so...
    dont tell me i was right???

  4. #4
    Non-Member hyperimage's Avatar
    Join Date
    Dec 2003
    Location
    Croatia
    Posts
    259
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    so practicaly is that right?
    PHP Code:
    <?php 
    $sql 
    mysql_query("SELECT * FROM  some_table ORDER BY id DESC LIMIT 1"); 
    if(
    $row mysql_fetch_array($sql));
    list(
    $width$height$type$attr) = getimagesize("$path/$image"); 
    $z $xw $xlw
    $i $yh $ylh
    for(
    $x=$z;$x<=$width;$x++) && for($y=$i;$y<=$height;$y++);
    ?>
    HTML Code:
    <style>
    .view {
    clip:rect (0,$x,$y,0)
    }
    </style>


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •