Page 1 of 2 12 LastLast
Results 1 to 10 of 18
  1. #1
    Elite Member
    Join Date
    May 2011
    Gender
    Male
    Posts
    1,465

    Default dealing w/ images


    mga boss unsai mas maau na practice in dealing w/ images? i.store sa database ang image or name/path ra sa image?
    kai mas pas2x man ug load kung sa path ra dba? pero ang nakabati kai maka.view ang user sa folder sa uploaded images, unlike kung sa database jud gi.store. any idea there? please post the advantages and the disadavantages. tnx. i'm still learning.

  2. #2
    The latter. Assuming na apache server imo gamit, setup lng ug .htaccess sa folder na dli nimo ganahan ipa view.

    .htaccess:
    Code:
    order allow deny
    deny from all
    Of course, daghan pa kaau kag mabuhat pero sa imoha lng na case, ok nani siya.

  3. #3
    for me, mas nice ang path ra. . imong database mura rag papel ang kagaanon. . .

  4. #4
    up ko ani kay kani pud ako gus2 mahibal.an karon sa video ug sa images..

  5. #5
    better kung dli db pra dli bugat...kung dka mg gamit ug framework need nmo ng ky kamahak

  6. #6
    Elite Member
    Join Date
    May 2011
    Gender
    Male
    Posts
    1,465
    Quote Originally Posted by ondoy View Post
    better kung dli db pra dli bugat...kung dka mg gamit ug framework need nmo ng ky kamahak
    i use CI boss hehehe.

  7. #7
    ibutang lang sa path ang images. Sakto ila suggestion, nakasuway sad ko ana nga problem before, but later na realize nako ang advantage. Kung sa database nmo ibutang versus path/folder...just think if you're dealing with millions and millions of records....dili lalim!

    ang gi.suggest ni kamahak, okay man pud through apache, straightforward walay daghan additional settings needed, but then dili na viewable ang images directory, tight and secure.

    If you want nga viewable ra ang mga images, by providing the correct path/file name....then lahi sad nga approach ang gamiton.

    in your images folder, add index.php.
    Code:
    <?php
    //Silence is Golden!  ^_^

  8. #8
    Elite Member
    Join Date
    May 2011
    Gender
    Male
    Posts
    1,465
    Quote Originally Posted by ChaosOrb View Post
    ibutang lang sa path ang images. Sakto ila suggestion, nakasuway sad ko ana nga problem before, but later na realize nako ang advantage. Kung sa database nmo ibutang versus path/folder...just think if you're dealing with millions and millions of records....dili lalim!

    ang gi.suggest ni kamahak, okay man pud through apache, straightforward walay daghan additional settings needed, but then dili na viewable ang images directory, tight and secure.

    If you want nga viewable ra ang mga images, by providing the correct path/file name....then lahi sad nga approach ang gamiton.

    in your images folder, add index.php.
    Code:
    <?php
    //Silence is Golden!  ^_^
    what about if akong i.delete ang image? how would i able to do it? or example a change the user's avatar, does that mean mag.overwrite rato ang image.name/path sa akong database then ang old image naa ra sa folder? in that case mapuno ang folder ug mga images na wa gamita ana in time. nag.learn pako ani. so please tell me how to do it in a good way


    and i think istorya.net is not using path, db ang gamit sa ila avatar.
    Last edited by jairoh_; 04-09-2013 at 06:24 PM.

  9. #9
    then delete the file that is physically associated with the record, you have the path of the image, locate it, then delete physically before adding a new one.

    ang technique para gaan imong image directory is to optimize the image into allowable size. you have to redraw/recreate the image somehow para gaan nlng inig load sa avatar. *hint: PHP GD2 Library.

  10. #10
    Elite Member
    Join Date
    May 2011
    Gender
    Male
    Posts
    1,465
    Quote Originally Posted by kamahak View Post
    The latter. Assuming na apache server imo gamit, setup lng ug .htaccess sa folder na dli nimo ganahan ipa view.


    .htaccess:
    Code:
    order allow deny
    deny from all

    Of course, daghan pa kaau kag mabuhat pero sa imoha lng na case, ok nani siya.
    boss if akong butangan ug
    order allow deny
    deny from all, di naman ma.view ang image gamit iya path, sa src ba

    Quote Originally Posted by ChaosOrb View Post
    then delete the file that is physically associated with the record, you have the path of the image, locate it, then delete physically before adding a new one.

    ang technique para gaan imong image directory is to optimize the image into allowable size. you have to redraw/recreate the image somehow para gaan nlng inig load sa avatar. *hint: PHP GD2 Library.
    yes mao na ako gbuhat. i thought nga naai saun na way sa pagdelete, manual pa diay japon.
    Last edited by jairoh_; 04-09-2013 at 07:02 PM.

  11.    Advertisement

Page 1 of 2 12 LastLast

Similar Threads

 
  1. How To Heal/Deal with Emotional Pains!!!
    By werty in forum "Love is..."
    Replies: 166
    Last Post: 03-09-2016, 07:26 PM
  2. SIGARILYO: On Smoking, Reasons why and How to deal/quit
    By babyGuRL in forum Fitness & Health
    Replies: 944
    Last Post: 04-05-2010, 12:57 PM
  3. Replies: 1273
    Last Post: 12-09-2008, 08:46 PM
  4. ~All about posting images/pics in iStorya.net~
    By medicus in forum Support Center
    Replies: 167
    Last Post: 08-01-2007, 02:01 PM
  5. unsaon pag pa enlarge sa image nga gi attached sa thread
    By dawn runner in forum Support Center
    Replies: 6
    Last Post: 03-26-2006, 01:10 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
about us
We are the first Cebu Online Media.

iSTORYA.NET is Cebu's Biggest, Southern Philippines' Most Active, and the Philippines' Strongest Online Community!
follow us
#top