Results 1 to 7 of 7

Thread: Not sure if this is the right place, but WP help.

  1. #1
    Lmp's Avatar
    Join Date
    Dec 2011
    Gender
    Location
    Toronto
    Age
    23
    Posts
    1,347
    Thanks
    264
    Thanked 575 Times in 194 Posts


    Downloads
    49
    Uploads
    0
    Mentioned
    320 Post(s)
    Time Online
    174 d 3 h 14 m
    Avg. Time Online
    2 h 12 m
    Rep Power
    10

    Not sure if this is the right place, but WP help.

    So I have this code which is part of a CSV Importer:


    Right now, when the importer imports a image, it names the image based on it`s URL (E.g imageshack.us/a/img585/4739/8jp6.png, would mean it would name it 8jp6.png).
    However, I want the importer to name it based on it`s WP Post Title. I tried to manipulate the code but failed, if anyone can help, it`d be much appreciated, thanks!
    Last edited by Lmp; 10-15-2013 at 02:05 AM.

  2. #2
    Little Brother


    Zachafer's Avatar
    Join Date
    Dec 2011
    Gender
    Posts
    1,206
    Thanks
    723
    Thanked 1,392 Times in 651 Posts


    Downloads
    81
    Uploads
    17
    Mentioned
    497 Post(s)
    Time Online
    21 d 17 h 32 m
    Avg. Time Online
    16 m
    Rep Power
    14

  3. The Following User Says Thank You to Zachafer For This Useful Post:

    Lmp (10-15-2013)

  4. #3
    Lmp's Avatar
    Join Date
    Dec 2011
    Gender
    Location
    Toronto
    Age
    23
    Posts
    1,347
    Thanks
    264
    Thanked 575 Times in 194 Posts


    Downloads
    49
    Uploads
    0
    Mentioned
    320 Post(s)
    Time Online
    174 d 3 h 14 m
    Avg. Time Online
    2 h 12 m
    Rep Power
    10
    Didn't work Zach :/. It still uses the basename. Here's the full plugin code. I'm using the "FeaturedImage" /function/.


  5. #4
    Little Brother


    Zachafer's Avatar
    Join Date
    Dec 2011
    Gender
    Posts
    1,206
    Thanks
    723
    Thanked 1,392 Times in 651 Posts


    Downloads
    81
    Uploads
    17
    Mentioned
    497 Post(s)
    Time Online
    21 d 17 h 32 m
    Avg. Time Online
    16 m
    Rep Power
    14
    Looks like you put my code into the saveImages($post_id) function, not the saveImageWithUrl function.

  6. #5
    Lmp's Avatar
    Join Date
    Dec 2011
    Gender
    Location
    Toronto
    Age
    23
    Posts
    1,347
    Thanks
    264
    Thanked 575 Times in 194 Posts


    Downloads
    49
    Uploads
    0
    Mentioned
    320 Post(s)
    Time Online
    174 d 3 h 14 m
    Avg. Time Online
    2 h 12 m
    Rep Power
    10
    I tried both, I tried saveImagewithUrl first, than tried playing around with the code but didn't work.
    @Zachafer

    Do you have to change something with the SaveImagewithName? Cause when saving the featured image, the function calls upon both saveimagewithurl and sameimagewithname?
    Last edited by Lmp; 10-15-2013 at 05:45 PM.

  7. #6
    Banned
    Join Date
    Jun 2012
    Gender
    Location
    90 90
    Age
    31
    Posts
    1,714
    Thanks
    876
    Thanked 2,877 Times in 1,139 Posts


    Downloads
    44
    Uploads
    1
    Mentioned
    562 Post(s)
    Time Online
    118 d 6 h 45 m
    Avg. Time Online
    1 h 30 m
    Rep Power
    0
    Gamer IDs

    Gamertag: DarkByt3 PSN ID: raredaredevil
    Did you get this working?

  8. #7
    Lmp's Avatar
    Join Date
    Dec 2011
    Gender
    Location
    Toronto
    Age
    23
    Posts
    1,347
    Thanks
    264
    Thanked 575 Times in 194 Posts


    Downloads
    49
    Uploads
    0
    Mentioned
    320 Post(s)
    Time Online
    174 d 3 h 14 m
    Avg. Time Online
    2 h 12 m
    Rep Power
    10
    Yeah, well not exactly, but I found another solution to my problem.

  9. The Following User Says Thank You to Lmp For This Useful Post:

    DarkByte (10-26-2013)

Posting Permissions

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