Jump to content

Hisashi

Friends
  • Posts

    433
  • Joined

 Content Type 

Downloads

Release Notes

IPS4 Guides

IPS4 Developer Documentation

Invision Community Blog

Development Blog

Deprecation Tracker

Providers Directory

Forums

Events

Store

Gallery

Posts posted by Hisashi

  1. Hello,

    I'm trying to make an edit in Most Contributions block, if you can help me with that I really appreciate it.

    I want to add a link in the number, redirecting to an area of user's profile > profile/x-user/content/?type=cms_records_review1&change_section=1

    Screenshot_228.png.5b736dd1c2f5d42a58f9d1149ddd6bb6.png 

     Screenshot_227.png.587306d3b3928aaa1d5646e23f89e13f.png

     

    To edit this block, go to: core > front > widgets > mostContributions

    <div>
    {$member->link()|raw}
    <br><span class='ipsType_light'>{{if $area}}{$contributions['counts'][$member->member_id]}{{else}}{$member->member_posts}{{endif}}</span>
    </div>

     

    If there was a parameter by example {User_Profile_Link}, i could do something like this...

    <br><a href="{User_Profile_Link}/content/?type=cms_records_review1&change_section=1"><span class='ipsType_light'>{{if $area}}{$contributions['counts'][$member->member_id]}{{else}}{$member->member_posts}{{endif}}</span></a>

     

    Does anyone know how I can make this edit?

  2. 3 minutes ago, Dexter_X said:

    I suggest you all to test one by one the existing rules (at least the ones you're interested in) and see if they behave like you expect...

    My follower is not working properly, at least the badge is not being given to the person who was followed

  3. I managed to do it in another way with the idea of @opentype
    I'll leave it here as a help, in case anyone looks for...
    ---------

    1. Create two pages (Manual HTML), one with a sidebar that you will mark as main page Screenshot_164.png.6e69b21ee8dabcbe4e47c488cee79520.png
    The other without sidebar (On this page you will place the database)

    Screenshot_163.png.52c3a4dfc9a29359106924db7204ce33.png

    2. Create a new block as per a screenshot

    Screenshot_167.png.692d9ca9840171a07060143c60e9a122.png

    Here you put your database (Don't enable "Cache this block")

    Screenshot_169.png.e5035807c96f3cfbf4d6fea9ae4ea3cd.png

     

    3. Now go to your main page and place the block with the database you just created.

    Screenshot_170.png.47859a93bec41ff066ad3b8d05a2b08c.png

     

    Now just add your blocks in sidebar and when you click it won't show.

    Thank you @Nathan Explosion for the other way to do this.

  4. 10 minutes ago, opentype said:

    Something to start with:

    {{if $formValue}}
    <div class="ipsGrid ipsGrid_collapsePhone">
    {{foreach $value as $file}}
      <div class="ipsGrid_span4 ipsSpacer_bottom">
    <img src="{file='$file' extension='cms_Records'}" class="ipsImage">
      </div>
    {{endforeach}}
    </div>
    {{endif}}

     

    Amazing, it worked well thank you!!

    Screenshot_159.png.cf712a359d146ee882eaa8eb633f8af7.png

    Since I'm going to use large images 1200x1800, I removed line

    <div class="ipsGrid_span4 ipsSpacer_bottom"></div>

    It worked well, is there a problem with that?

    Screenshot_162.thumb.png.ca2c28717c9ffc256c2dbed93ba043b0.png

     

  5. Hello,

    I'm trying to get multiple image upload field to work and I'm just getting frustrating results, could anyone help me?

    When I put an image it works, more than one it breaks.

    --------

    Current settings:

    Screenshot_150.png.a1270c74d660d392b97b41e96b360a26.png

    Screenshot_152.thumb.png.2c7fe433a5c7823e5b5258f79d56cbf1.png

    Screenshot_153.png.84e7045defd7309a0d3d3a309fee623b.png


    I added in Pages > templates > record

    {$record->customFieldDisplayByKey('upload_img', 'display')|raw}

     

    Result:

    Screenshot_155.png.4d7b6cea56d43bb668457c6ae6185b8b.png

    So I changed code in record to

    <img class="ipsImage" src="url/uploads/{$record->customFieldDisplayByKey('upload_img', 'display')|raw}">

    Result:

    Screenshot_157.png.d85d581451806364733afa7667da9820.png

    When will I put more than one image

    Screenshot_158.thumb.png.fd092eb14752c45df291b59330fe9260.png

    Result:

    Screenshot_156.png.93b1f21733896e29c73abc8989a2ea3f.png

     

    Does anyone know how to fix this? To be able to display multiple images

  6. 17 hours ago, Nathan Explosion said:

    Unfortunately, I think that block has a little JS code that acts against it and the above method isn't compatible.

    That specific block could probably be handled via a template edit instead (not fully tested - I'm going to bed):

    core -> front -> widgets -> mostContributors

    Enclose the template content with the following:

    {{if \IPS\Request::i()->controller==='page' AND !isset(\IPS\Request::i()->id)}}
    ALL THE EXISTING TEMPLATE
    {{endif}}

     

    Didn't work

  7. 39 minutes ago, Nathan Explosion said:

    I'm not confused - I'm clarifying your request to move from the general ("the blocks") to the specific ("the Recent Status Update block"), and your response confirms that it is the default blocks that you are asking about.

    The 'fix' is to use custom blocks instead, as follows (note: I am not providing what you put in to every field, I am providing the specific things that need to be done...the rest is up to you)

    1. ACP
    2. Pages -> Blocks -> Create Block
    3. In the second field ('Plugin') select the block you want to use ('Recent Status Updates')
    4. Give it a name (example: myBlock)
    5. Save this
    6. Pages -> Blocks -> Create Block
    7. This time, choose 'Custom' -> 'Manual HTML'
    8. On the first tab, name your custom block
    9. On the 'Content' tab, insert the code below
    10. On the same tab, DO NOT enable 'Cache this block'
    11. Save the new custom block
    12. Now, on the front-end you put that custom block in place, instead of the 'Recent Status Updates' block
    {{if \IPS\Request::i()->controller==='page' AND !isset(\IPS\Request::i()->id)}}
    {block="myBlock"}
    {{endif}}

    Why do it this way? The 'Recent Status Updates' block is cached, so adding the {{if....}} statement in its content will end up with strange caching results.

    Result (there may be some finesse needed, but there is your starting point):

     

    image.thumb.png.39a268e4a2306a9b6290c4d1ed51f6c3.png

     

    image.thumb.png.5787d0943a507143fb6a0b5f3997d4b2.png

     

     

    Amazing, it worked perfectly! Thanks

    I only had two problems...

    1. When I tried to replicate in "Popular contributors" disappeared the names.

    Screenshot_145.png.a9e60a6492712a6734a6388014127ed4.png

    2. In version 4.6.0 it worked, but in my 4.5.4.2 there was a space

    Screenshot_146.png.062da5a1510ffad4ff5122709f78f67a.png

     

  8. 1 hour ago, opentype said:

    All views of a database page have the same blocks, unless the visibility is coded into the block itself. 

    For a homepage, it can make sense not to use the article database itself but to create a new page and then put the article feed on there as a block. This gives more freedom regarding the blocks. I do that on one of my sites. This is the homepage with an article listing (as blocks) plus sidebar widgets. The actual article page is here without a sidebar. So it gives the result you ask for (in a way). 

    That's exactly what I want to do, I just don't understand how to do it hahah

    Screenshot_134.png.5d404e0d7b88cc7b5e07d2374e011bdb.png

    ---

    Thus, article without a block on sidebar

    Screenshot_135.thumb.png.5d6f6293c9be2d0d46cb108d90e41958.png

  9. On 11/21/2020 at 1:14 PM, SoftwareFactory said:

    1. We are looking for ways to deliver a greater notifications customizability while making them even easier to configure. But the default notification setting will also get better in a future update.

    2 and 3. I am pretty sure there are some bots out there that can do it for you.

    Yes, there are bots that do this, but I'm talking about enriching the app.

×
×
  • Create New...