Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Author Robert Heller

    (@robertpheller)

    This could probably be handled with clever stylesheet code, much in the same way the WP backend dashboard is handled.

    Thread Starter snips56

    (@snips56)

    Don’t suppose you have some of that clever stylesheet code around??? ??

    Perhaps for a future iteration, you could create a settings items for the search page (or maybe just an option on the inline parameters) that would allow you to choose the number of columns, like so many other WP plugins do?

    Thanks for this – I believe it will be helpful for our little woodworkers association, but would be even more useful if we could generate multiple columns and an upload/media library link function.

    Plugin Author Robert Heller

    (@robertpheller)

    Don’t suppose you have some of that clever stylesheet code around??? ??

    Nope. I barely understand stylesheets myself. Misquoting Dr. “Bones” McCoy: “Damit Jim, I’m a programmer, not a web designer!”.

    Thread Starter snips56

    (@snips56)

    OK – well maybe I’ll take a crack at that. Can you tell me what php or js file generates the output of search results?

    Plugin Author Robert Heller

    (@robertpheller)

    There is no js code involved. The short codes are implemented in the short_codes.php in the includes directory. The actual search code is in the database_code.php file.

    Hi!

    I did some changes in the default code, so the result is something like this:

    1. Italo Calvino: Végül arra száll egy holló
    2. Ráth-Végh István: A k?nyv komédiája
    3. Ulrich Plenzdorf: Die neuen Leiden des jungen W (suhrkamp taschenbuch)
    4. Bárczi Géza: A Halotti Beszéd nyelvt?rténeti elemzése
    5. Gulya János: A vízimadarak népe: Tanulmányok a finnugor rokon népek élete és m?veltsége k?réb?l

    “indexnumber.<tab>Author:Title” for each line, where “Title” is the only link to the item (but i can change it for you if needed) and it doesn’t shows the image of the item you uploaded.

    So, the changes in /includes/short_codes.php should be after “default:”:

    default:
    
    	$result .= '<span class="weblib-item-brief weblib-item-info weblib-item-element">';
    	$result .= $item->author();
    	if ($item->callnumber() != '') {
    	  $result .= '<br />'.__('Call Number:','web-librarian').'&nbsp;'.$item->callnumber();
    	}
    	$result .= ': ';
    	if ($moreinfourl != '') {
    	  $result .= '<a href="'.add_query_arg(array('barcode' => $barcode),
    						$moreinfourl).'">';
    	}
    	$result .= $item->title();
    	if ($moreinfourl != '') {$result .= '</a>';}

    and changes in the /css/front.css should be:

    .weblib-item-index {
      font-size: 100%;
      padding: 0px 4px;
      text-align: left;
      width: 5%;
    }

    I reduced the index number’s size cause it looks better when you have shorter lines.

    Please, let me know if it’s okay for you!

    Thread Starter snips56

    (@snips56)

    Thanks zoltanheczog

    Unfortunately, while that tightens up the listing, it isn’t what I was asking for. I was looking for a tabular format – that is, a table – with rows and columns. That way I should be able to see four (or whatever number I wish) book images across the first row, then a row break and four more and so on until I reach the pagination limit – maybe 20 books at a time in five rows of four columns. I don’t want to lose the thumbnails, but rather would like to not have them in a single column. I hope this makes sense. Thanks again.

    Lee Jones

    (@cypresschurch)

    I did something similar with columns (I didn’t want to parse with an “each()” loop). You can inspect the elements on my landing page (still a work in progress) at library dot cypresschurch dot net. https://library.cypresschurch.net/

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Tabular display’ is closed to new replies.