Announcement

Collapse
No announcement yet.

Some changes to the CMS

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • rubenban
    replied
    Originally posted by NudnikStudios View Post

    I have this issue with videos not displaying on the front page of the CMS as well but I'm running into a bit of an issue trying to follow your instructions. When I go to line 440 of my display_contenttype_conversationreply_Text it doesn't say what yours does. Instead I see

    PHP Code:
    {vb:action parsedTextbbcodeparseNodePreview, {vb:var conversation.nodeid}}
    <
    vb:else />
    {
    vb:action parsedTextbbcodeparseNodeText, {vb:var conversation.nodeid}, 0, {vb:var page.contentpagenum}}
    </
    vb:if>
    <
    vb:if condition="isset($reportActivity) AND $reportActivity AND $conversation['previewimage']">
    {
    vb:data canGetImgAttachmentuserhasPermissionsforumpermissions2cangetimgattachment, {vb:raw conversation.nodeid}}
    <
    vb:if condition="$canGetImgAttachment"
    Is this possibly a version issue or am I likely just screwing something up? Thanks for your time if you can find any to reply to this.

    It's the same more or less. I was customizing the template, so maybe is not exactly line 440 for you. But just look for the code I said, you will find it near line 440. Then you can do the replacement.

    Leave a comment:


  • Wayne Luke
    replied
    That is because templates can change every version to add new features and bugs. This is why we don't recommend editing the templates.

    Leave a comment:


  • NudnikStudios
    replied
    Originally posted by rubenban View Post
    Again I have to solve the problem alone. I'm not happy at all with the vBulletin support. All the modifications was done to the templates through AdminCP, so it was possible. But you have to want to help to your customers:


    SOLUTION
    The solution is easy if you use some CSS and a little edit in the template:

    Go to AdminCP > Styles & templates > Your Template (Edit templates)

    Then look for "Show Templates" and then, look for this: display_contenttype_conversationreply_Text

    Go to line 440 where you will find this:

    PHP Code:
    <div class="post-content restore js-post__content-text h-wordwrap" {vb:schema {vb:raw textSchema}}>
    <
    vb:if condition="isset($reportActivity) AND $reportActivity AND !$vmDetail">
    {
    vb:action parsedTextbbcodeparseNodePreview, {vb:var conversation.nodeid}}
    <
    vb:else />
    {
    vb:action parsedTextbbcodeparseNodeText, {vb:var conversation.nodeid}, 0, {vb:var page.contentpagenum}}
    </
    vb:if> 
    You have to replace it for this code:

    PHP Code:
    <vb:if condition="isset($reportActivity) AND $reportActivity AND !$vmDetail">
    <
    div id="previewarticulo" class="post-content restore js-post__content-text h-wordwrap limitador" {vb:schema {vb:raw textSchema}}>
    {
    vb:action parsedTextbbcodeparseNodeText, {vb:var conversation.nodeid}, 0, {vb:var page.contentpagenum}}
    <
    vb:else />
    <
    div class="post-content restore js-post__content-text h-wordwrap" {vb:schema {vb:raw textSchema}}>
    {
    vb:action parsedTextbbcodeparseNodeText, {vb:var conversation.nodeid}, 0, {vb:var page.contentpagenum}}
    </
    vb:if> 

    What we are doing here is first using different DIV's (one for the preview in the HOME of your page and other for the full article) and of course a different class named "limitador" to show only a preview of the article with a max-height of 550 pixels (you can edit this height in the CSS to your needs). Of course it will show images and videos in the top of your articles, without restrictions.


    To finish, it's important to edit the template inside "CSS templates" called css_additional.css and add this line:

    Code:
    .limitador{overflow:hidden;max-height: 550px;}


    And that's all, now you have a CMS that really looks like a blog, example: http://justunboxing.com/upload
    I have this issue with videos not displaying on the front page of the CMS as well but I'm running into a bit of an issue trying to follow your instructions. When I go to line 440 of my display_contenttype_conversationreply_Text it doesn't say what yours does. Instead I see

    PHP Code:
                                {vb:action parsedTextbbcodeparseNodePreview, {vb:var conversation.nodeid}}
                            <
    vb:else />
                                {
    vb:action parsedTextbbcodeparseNodeText, {vb:var conversation.nodeid}, 0, {vb:var page.contentpagenum}}
                            </
    vb:if>
                            <
    vb:if condition="isset($reportActivity) AND $reportActivity AND $conversation['previewimage']">
                                {
    vb:data canGetImgAttachmentuserhasPermissionsforumpermissions2cangetimgattachment, {vb:raw conversation.nodeid}}
                                <
    vb:if condition="$canGetImgAttachment"
    Is this possibly a version issue or am I likely just screwing something up? Thanks for your time if you can find any to reply to this.

    Leave a comment:


  • Wayne Luke
    replied
    You can see what templates are used where by setting the option to insert template names in the output. AdminCP -> Settings -> Options -> General Settings -> Add Template Names to HTML Output. As support, we often have to use the same functionality to find code. As templates get more complex, we don't necessarily know where the code is. Especially in the heavily javascript influenced vBulletin 5 which expanded the template language significantly. The resulting HTML might not actually be in a template but generated on the fly.

    Once the above setting is on, you can view the page source to see the templates that were used.

    Leave a comment:


  • rubenban
    replied
    I didn't know that you don't support modifying templates either. I thought you supported any change made from the AdminCP or SiteBuilder. Sometimes we just need something like "Take a look in this template". As you develop the software, you know better than users what templates contain the information of every part of the site, so if you tell me what is the template I can edit and customize it to my needs, if not I have to spend hours looking for the template I need to modify. Thats the way how I could make my site looks as I wanted.

    I have asked only 3 times in this forum and I have never had help with my issues. I had to investigate for myself to solve the problems, and that's not good. I will try next time in vbulleting.org.

    Kind regards.

    Leave a comment:


  • Wayne Luke
    replied
    I am glad that you were able to figure it out. Modifying code, including templates, is outside the scope of support. If we do have time and can figure out the answer to a modification request quickly, we will provide it as best we can. Code modifications should be handled at vBulletin.org. If you want to suggest these changes be made globally, you can put in an improvement request here: http://tracker.vbulletin.com/secure/...91&issuetype=4

    Any Bugs you encountered should be entered here: http://tracker.vbulletin.com/secure/...91&issuetype=1

    Leave a comment:


  • rubenban
    replied
    Again I have to solve the problem alone. I'm not happy at all with the vBulletin support. All the modifications was done to the templates through AdminCP, so it was possible. But you have to want to help to your customers:


    SOLUTION
    The solution is easy if you use some CSS and a little edit in the template:

    Go to AdminCP > Styles & templates > Your Template (Edit templates)

    Then look for "Show Templates" and then, look for this: display_contenttype_conversationreply_Text

    Go to line 440 where you will find this:

    PHP Code:
    <div class="post-content restore js-post__content-text h-wordwrap" {vb:schema {vb:raw textSchema}}>
    <
    vb:if condition="isset($reportActivity) AND $reportActivity AND !$vmDetail">                          
                             {
    vb:action parsedTextbbcodeparseNodePreview, {vb:var conversation.nodeid}}
     <
    vb:else />
                             {
    vb:action parsedTextbbcodeparseNodeText, {vb:var conversation.nodeid}, 0, {vb:var page.contentpagenum}}
    </
    vb:if> 
    You have to replace it for this code:

    PHP Code:
    <vb:if condition="isset($reportActivity) AND $reportActivity AND !$vmDetail">
    <
    div id="previewarticulo" class="post-content restore js-post__content-text h-wordwrap limitador" {vb:schema {vb:raw textSchema}}>
    {
    vb:action parsedTextbbcodeparseNodeText, {vb:var conversation.nodeid}, 0, {vb:var page.contentpagenum}}
    <
    vb:else />
    <
    div class="post-content restore js-post__content-text h-wordwrap" {vb:schema {vb:raw textSchema}}>
    {
    vb:action parsedTextbbcodeparseNodeText, {vb:var conversation.nodeid}, 0, {vb:var page.contentpagenum}}
    </
    vb:if> 

    What we are doing here is first using different DIV's (one for the preview in the HOME of your page and other for the full article) and of course a different class named "limitador" to show only a preview of the article with a max-height of 550 pixels (you can edit this height in the CSS to your needs). Of course it will show images and videos in the top of your articles, without restrictions.


    To finish, it's important to edit the template inside "CSS templates" called css_additional.css and add this line:

    Code:
    .limitador{overflow:hidden;max-height: 550px;}


    And that's all, now you have a CMS that really looks like a blog, example: http://justunboxing.com/upload
    Last edited by rubenban; Mon 9 Feb '15, 5:07am.

    Leave a comment:


  • Wayne Luke
    replied
    It is shortened in the code. We don't support code changes to the files.

    Leave a comment:


  • rubenban
    replied
    Yes, I already tried in forumdisplay options and showthread but any of them work. Is there any php file or template where I can edit this limit until this bug is fixed?
    Last edited by rubenban; Thu 29 Jan '15, 2:26pm.

    Leave a comment:


  • Wayne Luke
    replied
    That would be a bug then.

    Leave a comment:


  • Glenn Vergara
    replied
    Originally posted by Wayne Luke View Post
    Character limit of previews (Articles, topics, etc...) is the option under Settings -> Options -> Topic Display Options (forumdisplay) -> Length of Preview Text. Default is 150 characters.
    That's Forum Display Options not Topic Display Options and that's what I suggested in post #4 and it seems that doesn't work for Articles.

    There is Topic Display Options (showthread) > Preview Text Length but that doesn't seem to work either.

    Leave a comment:


  • Wayne Luke
    replied
    Character limit of previews (Articles, topics, etc...) is the option under Settings -> Options -> Topic Display Options (forumdisplay) -> Length of Preview Text. Default is 150 characters.

    Leave a comment:


  • rubenban
    replied
    Thank you everyone. I will customize all templates through SiteBuilder then, instead CSS files. Thanks for the stylevars list too.
    Any help with the character limit of articles preview and the problem showing videos and images in the previews? I need to solve this to put my site finally in production.

    Regards.

    Leave a comment:


  • Wayne Luke
    replied
    Current list of all stylevars will be found here: http://www.vbulletin.com/forum/stylevars

    Leave a comment:


  • Glenn Vergara
    replied
    3. That was for the length of preview text (not title) in forum posts. I was not sure if that is also applied in article posts.

    5. It is NOT recommended to modify the core css files. That would be a maintenance nightmare!
    To customize your site, you need to modify the stylevars and/or css_additional.css template via Sitebuilder (preferred) or AdminCP.
    Here's the full list of stylevars available:

    http://www.vbulletin.com/forum/forum...ions-full-list

    And in this link are the steps to determine if the style of a particular element on a page has stylevars or not.

    http://www.vbulletin.com/forum/forum...30#post4182030

    If a stylevar is available for an element, you customize it in the Style Variable editor in AdminCP. Otherwise you customize it in css_additional.

    Leave a comment:

Related Topics

Collapse

Working...
X