May 4, 2011

Image attachment details | CyberSEO Pro | Support Forum

Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

sp_TopicIcon
Image attachment details
Topic Rating: 0 Topic Rating: 0 Topic Rating: 0 Topic Rating: 0 Topic Rating: 0 Topic Rating: 0 (0 votes) 
October 9, 2017
8:50 am
Avatar
EonBlue
Member
Members
Forum Posts: 4
Member Since:
October 9, 2017
sp_UserOfflineSmall Offline

Searched existing posts but couldn’t find an answer.

When adding galleries with Cyberseo is it possible to populate other fields of the image Attachment Details besides title?

This code adds the image and image title:

Login to see the quote

Does the ‘cseo_add_image_to_library’ function accept any other parameters to fill the other fields (caption, alt, description)?

Or is there another snippet of code that can be added to the loop to insert the other info directly?

October 9, 2017
9:43 am
Avatar
CyberSEO
Admin
Forum Posts: 3706
Member Since:
July 2, 2009
sp_UserOfflineSmall Offline

The CyberSEO plugin uses standard WordPress API function Login to see this link to add images into the library. The images in WordPress gallery don’t have captions, alt descriptions etc. Only mime type, title, guid, status etc…

October 9, 2017
10:07 am
Avatar
EonBlue
Member
Members
Forum Posts: 4
Member Since:
October 9, 2017
sp_UserOfflineSmall Offline

Check this image:

Login to see this link

When I click on images in a post gallery I get the same box. I can enter the info manually and then display it where I need to.

The ‘post_title’ that is being inserted by the cseo function is the same one that shows up under Attachment Details. Surely there must be a way to insert the rest of that info automatically. 

Check this page:

Login to see this link

Login to see the quote

And this from the Wordpress API link you provided:

Login to see the quote

I want to get something into the ‘post_content’ value in the array which should then show up in the ‘Description’ field under Attachment Details.

October 9, 2017
10:27 am
Avatar
CyberSEO
Admin
Forum Posts: 3706
Member Since:
July 2, 2009
sp_UserOfflineSmall Offline

Do you see that WordPress does not allow anything other that those array fields, quoted in your post above? A WordPress theme can do almost anything (add the alt titles, alt images etc), but CyberSEO can no do that. It does not render the image galleries. Your theme does that.

October 9, 2017
10:41 am
Avatar
EonBlue
Member
Members
Forum Posts: 4
Member Since:
October 9, 2017
sp_UserOfflineSmall Offline

Yes, I understand that. But I am not talking about display of information right now. I am talking about adding information into the WP database which is where Cyberseo comes in. This is regardless of theme.

All I want to do is get a value into the ‘post_content’ field of that array using the <?php…?> box in Cyberseo when a new gallery is added. Unless I am mistaken it seems it is a standard Wordpress field so I assume there must be a way to do it.

October 10, 2017
3:20 am
Avatar
CyberSEO
Admin
Forum Posts: 3706
Member Since:
July 2, 2009
sp_UserOfflineSmall Offline

Yes, it’s a standard field. You can insert any text or HTML code there using the “Post content” box: Login to see this link

October 10, 2017
6:49 pm
Avatar
EonBlue
Member
Members
Forum Posts: 4
Member Since:
October 9, 2017
sp_UserOfflineSmall Offline

You are misunderstanding me.

I know the about “Post content” box for a new post containing a gallery.

But, according to the Wordpress docs, each image added to a gallery as an attachment in a post becomes its own post and can be assigned it own “post content” (which becomes description). The Cyberseo plugin is assigning a “post title” to each of these image attachments so I don’t see why it can’t also assign a “post content” value to the image attachments.

Is it possible for you to send me the lines of the ‘cseo_add_image_to_library’ function so I can try to figure it out for myself? Or can you give me a quote for custom code to do it?

October 31, 2017
8:52 am
Avatar
CyberSEO
Admin
Forum Posts: 3706
Member Since:
July 2, 2009
sp_UserOfflineSmall Offline

Sure. Here is the code:

Login to see the code

Forum Timezone: Europe/Amsterdam

Most Users Ever Online: 541

Currently Online:
15 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

ninja321: 84

s.baryshev.aoasp: 64

Freedom: 61

MediFormatica: 49

B8europe: 47

saviulisse67: 45

Member Stats:

Guest Posters: 338

Members: 2666

Moderators: 0

Admins: 1

Forum Stats:

Groups: 1

Forums: 5

Topics: 1547

Posts: 7821

Newest Members:

fairriverllc, josepatricioperalta, goran.o.aroga, betomanzoli, monefff, petergalanko

Administrators: CyberSEO: 3706