Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#121 2011-07-06 12:34:50

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 10,568
Website GitHub

Re: smd_bio : store additional biographical info about your users

Bizarre. Looks all ok to me (well, I’d farm out the duplicated <div id="profile"> block to a second form so I only needed to edit it in one place in future, but that’s just me).

Did debug="1" show some replacements available for either / both outputs? Must admit I’m stumped at the moment.


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#122 2011-07-06 12:40:35

Destry
Member
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,753
Website

Re: smd_bio : store additional biographical info about your users

Bloke wrote:

Did debug="1" show some replacements available for either / both outputs?

Oh, yeah, forgot to mention that. No, it’s not showing anything. I’m expecting a list or something to appear like a tag trace, but there’s nothing.

The only other plugin installed at the moment is vpl_tweet, which is miniscule. Can’t be that.

I’m headed out for streets for a while.

Offline

#123 2011-07-06 14:07:17

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 10,568
Website GitHub

Re: smd_bio : store additional biographical info about your users

Destry wrote:

No, it’s not showing anything. I’m expecting a list or something to appear like a tag trace, but there’s nothing.

Right, so the plugin is doing what it’s supposed to be doing in the output department at least, it’s just that it’s not picking up the bio info from the author of the article, so it has nothing to display.

Can’t think why that might be offhand. Erm… I’ll put my brain in and see if anything hits me.

If you find anything out by randomly stabbing in the dark with the tags or going back to basics, let me know. I would check that all bio info is set correctly for the author of the article (in the smd_bio table. You should be able to match up the authors since their login name will be the same as their TXP login). Then put a <txp:author title="0" /> tag in your smd_bio forms to check that TXP is “seeing” an author at the relevant points.

If that checks out ok, try wrapping <txp:smd_bio_author> around your smd_bio_info tags and give it a known author just to check that the plugin is working on “fixed” usernames. Your findings might help me figure out what’s going on. Thanks.

Last edited by Bloke (2011-07-06 14:09:40)


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#124 2011-07-06 15:23:35

Destry
Member
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,753
Website

Re: smd_bio : store additional biographical info about your users

Figured it out. I am the silliest knucklehead. I had created the initial bio articles for other people, and forgot to change author on the articles. Nothing was showing because none of the bios were mine. Ha!

Once I did that little dance, all’s good!

Sorry for all that, Bloke. Drink on me in London.

Last edited by Destry (2011-07-06 15:25:26)

Offline

#125 2011-07-06 15:25:47

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 10,568
Website GitHub

Re: smd_bio : store additional biographical info about your users

Destry wrote:

Figured it out

Phew, glad it’s working now. I was getting mighty confused there.

I’ll go and put my brain back in its box for another day…


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#126 2011-07-06 15:35:04

Destry
Member
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,753
Website

Re: smd_bio : store additional biographical info about your users

Oh, one more question. How do I actually see replacement keys (the “names”, I guess) of the core user account data types so I can use them in similar ways? I think that was a feature of the older version, right? (E.g., author name). Seems like replacement keys are a good way to save some characters in the tag magic.

Offline

#127 2011-07-06 15:49:55

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 10,568
Website GitHub

Re: smd_bio : store additional biographical info about your users

Destry wrote:

How do I actually see replacement keys (the “names”, I guess) of the core user account data types

I just throw debug="1" in the smd_bio_info tag and it spits out an array. The column on the left are the {replacements} you can use in the container and the stuff on the right is the content you’ll get back.

EDIT: Shame there’s not a more elegent way. The useful ones are {smd_bio_*name_of_your_field*} for the value or {smd_bio_*name_of_your_field*_title} for the label.

EDIT 2: Ah, do you mean the core fields? You have a choice of user_id, login, RealName, email or privs I think, off the top of my head.

Last edited by Bloke (2011-07-06 15:59:34)


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#128 2011-07-06 15:55:52

Destry
Member
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,753
Website

Re: smd_bio : store additional biographical info about your users

Sorry, I don’t think I was clear. I don’t mean my custom data types, but the data types from the core Txp user account fields. Are those listed in the wiki somewhere? I think you had a list of them in your plugin doc in the previous version.

Offline

#129 2011-07-06 15:59:20

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 10,568
Website GitHub

Re: smd_bio : store additional biographical info about your users

Destry wrote:

the data types from the core Txp user account fields

Wasn’t you being unclear, it was me being dense. See Edit above. Also, yes, they’re in the docs under the ‘fields’ attribute of smd_bio_info.

Last edited by Bloke (2011-07-06 16:00:01)


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#130 2011-07-06 16:26:17

Destry
Member
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,753
Website

Re: smd_bio : store additional biographical info about your users

Got it! I think we’re done here. (He says.)

Offline

#131 2011-07-11 11:53:46

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 10,568
Website GitHub

Re: smd_bio : store additional biographical info about your users

stephan wrote:

I am using smd_bio 0.3.1 and I can’t seem to be able to store more than 64 characters in a textarea field

Yes, bogus code, sorry. Drop me a line if you want to try out v0.40 which lifts this restriction and allows you to choose the size of field. It’s not 100% backwards compatible so expect some tag fallout, but I’ve tried wherever I can to throw warnings to let you know what’ll need changing.

EDIT: oh, wait, no. 64 chars is the maximum you can store for an author name in Txp itself. No getting round that without manually modding the database.

Last edited by Bloke (2011-07-11 11:54:52)


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#132 2011-07-11 11:55:50

stephan
Plugin Author
From: Bochum, Germany
Registered: 2004-07-26
Posts: 196
Website

Re: smd_bio : store additional biographical info about your users

Ups, I just re-did the bio config and it works, so I decided to quickly delete my post before anyone notices. Obviously you noticed ;-)
Let’s forget it for now and I shall happily wait for the officla v.0.40 release :)


Yoko for Textpattern – A free blog themeMinimum Theme – If all you want to do is write.
Note: I am currently not actively using Textpattern, so I am not in the forums very often

Offline

Board footer

Powered by FluxBB