View Single Post
  #35  
Old 12-04-2006, 09:56 AM
Greek Wizard Greek Wizard is offline
 
Join Date: Jun 2006
Posts: 94
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I think I found the problem regarding the above issue, but I am not a coder, etc, so I can't help fix it properly and as such broke it a little, but with much minor issues. I did however fix it for my needs, and until a proper fix comes from someone that knows what they are doing as opposed to me, then I will use it since it's better than above I think. Again, please realize, I really have no idea what I am doing, so back up your arcade.php file if you want to try this.

That said, I added some hard coded text because my "fix" disabled the $costhtmlstart and removed the "Costs to play" text, as again, I really have no idea what I am doing here. Anyways, this is what I did, and hopefully from that Mr. Z can find a proper fix for us.

Basicly all I did was change $costhtmlstart .= to $costhtmlstart = (took the period out) and that fixed it (but caused other smaller issues), added the hard Coded vbbux text and a <br />

Open arcade.php

Find:

Code:
		// detect vBplaza
		if (($vbulletin->options['vbbux_enabled'] == 1) && ($vbulletin->options['vbbux_arcadeintegration'] == 1))
		{
			$costhtmlstart	= "<br /><span class=\"smallfont\">".$ibforums->lang['costs_tourneyj'];
			$costhtmlend	= "</span>";
		}

		$DB->query("SELECT t.nbtries, t.plibre, t.creat, t.gid, t.numplayers,t.datestarted,t.tid,t.champion,t.cost,g.gtitle FROM ibf_tournaments as t, ibf_games_list as g WHERE t.gid = g.gid AND demare = 0 ORDER BY datestarted DESC");
		while($row = $DB->fetch_row()) {
			$row['link'] = "<a href='".$ibforums->vars['base_url']."do=viewtourney&amp;tid=".$row['tid']."'>".$ibforums->lang['see_this_tourney']."</a>";

			if ($costhtmlstart!="")
			{
				// add the costs to HTML and format it (vBplaza-Setting!)
				$costhtmlstart .= vb_number_format($row['cost'], $vbulletin->options['vbbux_decimalplaces']);
			}

			$row['inscrire'] = "<a href='".$ibforums->vars['base_url']."do=registertourney&amp;tid=".$row['tid']."'>".$ibforums->lang['register']."</a>".$costhtmlstart.$costhtmlend;
			$i=0;
Replace with:

Code:
		// detect vBplaza
		if (($vbulletin->options['vbbux_enabled'] == 1) && ($vbulletin->options['vbbux_arcadeintegration'] == 1))
		{
			$costhtmlstart	= "<br /><span class=\"smallfont\">".$ibforums->lang['costs_tourneyj'];
			$costhtmlend	= " vbBux to play</span>";
		}

		$DB->query("SELECT t.nbtries, t.plibre, t.creat, t.gid, t.numplayers,t.datestarted,t.tid,t.champion,t.cost,g.gtitle FROM ibf_tournaments as t, ibf_games_list as g WHERE t.gid = g.gid AND demare = 0 ORDER BY datestarted DESC");
		while($row = $DB->fetch_row()) {
			$row['link'] = "<a href='".$ibforums->vars['base_url']."do=viewtourney&amp;tid=".$row['tid']."'>".$ibforums->lang['see_this_tourney']."</a>";

			if ($costhtmlstart!="")
			{
				// add the costs to HTML and format it (vBplaza-Setting!)
				$costhtmlstart = vb_number_format($row['cost'], $vbulletin->options['vbbux_decimalplaces']);
			}

			$row['inscrire'] = "<a href='".$ibforums->vars['base_url']."do=registertourney&amp;tid=".$row['tid']."'>".$ibforums->lang['register']."</a><br />".$costhtmlstart.$costhtmlend;
			$i=0;
A screen shot is attached, so that you can see the result.
Attached Files
File Type: (21.3 KB, 31 views)
Reply With Quote
 
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01364 seconds
  • Memory Usage 1,799KB
  • Queries Executed 12 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD_SHOWPOST
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_code
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_box
  • (1)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit_info
  • (1)postbit
  • (1)postbit_attachment
  • (1)postbit_onlinestatus
  • (1)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • reputationlevel
  • showthread
Included Files:
  • ./showpost.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showpost_start
  • bbcode_fetch_tags
  • bbcode_create
  • postbit_factory
  • showpost_post
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • showpost_complete