PageSourceSearch

https://www.ad-hoc-news.de/js/script.js

js ad-hoc-news.de collected 2026-10-01 10:13:18 UTC 9,750 bytes, 290 lines download raw bytes

1$(document).ready(function(){
2
3	//$("body").tooltip({ selector: '[data-toggle=tooltip]' }); // wird scheinbar nicht benutzt --> 30.01.2017
4
5	// toggle the sort on the Discount column v2.9!
6	$("#sort_topFlop").click(function() {
7		$('#sort_aZ').switchClass( ' btn-warning ', ' btn-default ' );
8		$('#sort_aZ').html('A bis Z');
9		$(".courselist-desktop").find("th:contains(Prozent)").trigger("sort");
10		$(".watchlist-desktop").find("th:contains(Prozent)").trigger("sort");
11		if($(".sorting_table th").hasClass( 'tablesorter-headerDesc' ) == true){
12			$('#sort_topFlop').html('TopFlop <i class="fas fa-long-arrow-down" aria-hidden="true"></i>');
13		}
14		if($(".sorting_table th").hasClass( 'tablesorter-headerAsc' ) == true){
15			$('#sort_topFlop').html('TopFlop <i class="fas fa-long-arrow-up" aria-hidden="true"></i>');
16		}
17		$('#sort_topFlop').switchClass( ' btn-default ', ' btn-warning ' );
18		return false;
19	});
20	$("#sort_aZ").click(function() {
21		$('#sort_topFlop').switchClass( ' btn-warning ', ' btn-default ' );
22		$('#sort_topFlop').html('TopFlop');
23		$(".courselist-desktop").find("th:contains(Aktie)").trigger("sort");
24		$(".watchlist-desktop").find("th:contains(Aktie)").trigger("sort");
25		if($(".sorting_table th").hasClass( 'tablesorter-headerDesc' ) == true){
26			$('#sort_aZ').html('A bis Z <i class="fas fa-long-arrow-down" aria-hidden="true"></i>');
27		}
28		if($(".sorting_table th").hasClass( 'tablesorter-headerAsc' ) == true){
29			$('#sort_aZ').html('A bis Z <i class="fas fa-long-arrow-up" aria-hidden="true"></i>');
30		}
31		$('#sort_aZ').switchClass( ' btn-default ', ' btn-warning ' );
32		return false;
33	});
34
35	setTimeout(function(){
36	  $('.article-continue').fadeIn( 3000 );
37	}, 2000);
38
39	$(".courselist-desktop").tablesorter({
40		theme : 'ice',
41		sortList: [[4,1]]
42	});
43	$(".watchlist-desktop").tablesorter({
44		theme : 'ice',
45		sortList: [[3,1]]
46	});
47	$(".courselist-mobile").tablesorter({
48		theme : 'ice',
49		sortList: [[3,1]]
50	});
51	$(".watchlist-mobile").tablesorter({
52		theme : 'ice',
53		sortList: [[2,1]]
54	});
55	$("#searchStock-tbl").tablesorter({
56		theme : 'ice'
57	});
58
59	$('body').on('click', '.term-title', function(){
60		var id = $(this).attr('id');
61		$('.'+id).slideToggle();
62//		console.log($(this).attr('id'));
63	});
64
65	$('body').on('click', '.range-switch', function(e){
66		 e.preventDefault();
67		 iRange = $(this).attr('id');
68		 iRangeSplit = iRange.split('_');
69
70		 $('.mostread-section-box-'+iRangeSplit[0]).hide();
71		 $('.mostread-section-box-container-'+iRangeSplit[0]+'-'+iRangeSplit[1]).show();
72		 $(this).parent().find('.active').removeClass('active');
73		 $(this).addClass('active');
74	});
75
76
77	$('body').on('click', '#close-submenue', function(){
78		$('#show-more-subs-content').slideUp();
79	});
80	$('body').on('click', '#show-more-subs-btn', function(){
81		$('#show-more-subs-content').slideToggle(function(){
82			if ($(this).is(':visible') == false) {
83			  $('#show-more-subs-btn').html('<i class="fas fa-angle-down"></i>');
84		  } else {
85			  $('#show-more-subs-btn').html('<i class="fas fa-angle-up"></i>');
86		  }
87		});
88	});
89
90
91	$(".top").hide();
92	$(window).scroll(function () {
93		if ($(this).scrollTop() > 100) {
94	    	$('.top').fadeIn();
95		} else {
96			$('.top').fadeOut();
97		}
98	});
99	$('.top').click(function () {
100		$('body,html').animate({scrollTop: 0}, 800);
101		return false;
102	});
103
104	/* Aufklappen des Hauptmenüs */
105	$('body').on('click', '#pull', function(e) {
106		e.preventDefault();
107		$('#ul-mobile-navi').slideToggle();
108		$('#mobile-search').slideToggle();
109	});
110	/* Aufklappen des Hauptmenüs */
111
112	$('body').on('click', '#pull-produkte', function(e) {
113		e.preventDefault();
114		$('#ul-mobile-navi-produkte').slideToggle();
115	});
116
117	$('#artilce-print').click(function(e){
118		e.preventDefault();
119		window.print();
120	});
121
122	// blendet den "weiterlesen.." Button in der Artikelansicht ein
123	$('.readMore').delay(500).fadeIn("slow");
124
125  	$('#sub-text').find('img').addClass('img-responsive');
126
127  	updateContainer();
128  	showBanner();
129	$(window).resize(function(){
130		updateContainer();
131		showBanner();
132		// Seite Neuladen später für die Werbung
133		//window.location.reload();
134	});
135
136	// Funktion die das jeweilige Fenster der Chartbox anzeigt
137	$('body').on( "click", ".range-switch-charts", function(e) {
138		e.preventDefault();
139		var id = $(this).attr('id');
140    	$('.chartbox-content').hide();
141    	$('.'+ id).show();
142    	$(this).parent().find('.active').removeClass('active');
143    	$(this).addClass('active');
144    	$.cookie("chart_choice", id, { path: '/', expires: 7 });
145	});
146
147	$('button.back').click(function(e){
148		e.preventDefault();
149		parent.history.back();
150		return false;
151	});
152
153  $('body').on('click', '.rss_toggle-question', function(){
154	  var id = $(this).attr('id');
155	  if($('.'+id).is(':visible') == false){
156		  $('.'+id).slideDown();
157		  $('#icon-'+id).html('<i class="fas fa-minus-square"></i>');
158	  }else{
159		  $('#icon-'+id).html('<i class="fas fa-plus-square"></i>');
160		  $('.'+id).slideUp('slow');
161	  }
162  });
163
164  /* RSS FEED */
165  $('#btn-genrsslink').click(function(e) {
166	  e.preventDefault();
167	  gen();
168	  $('.url-permarsslink').css({ fontWeight: 'bold', fontSize: '1em', lineHeight: '1.3rem' });
169  });
170
171  // hier wird ein tastaturbefehl angebunden
172  // und in dieser dann die gen() Funktion aufgerufen die den Link der xml zusammenbaut
173  $('#inp-genrsslink').bind('keyup', function() {
174    gen();
175  });
176  /* RSS FEED */
177
178  // Das Menü nochmal am Ende der seite
179  $('#main-navi-again-head').click(function(event){
180	  event.preventDefault();
181	  $('.main-navi-again-content').toggle();
182	  var height = $(document).height();
183	  $('body').scrollTop(height);
184  });
185
186}); // Ende document ready
187
188
189// Ab hier funktionen ==========================================
190
191// Generiert den RSS Link
192function gen(){
193	var sBasisUrl = '/rss/';
194	// hier werden aus dem string die * \ / und Leerzeichen entfernt, also mit nichts ersetzt
195	// und zu kleinbuchstaben umgewandelt
196	var kwd = $('#inp-genrsslink').val().replace(/\*/g, '').replace(/\//g, '').replace(/\\/g, '').replace(/ /g, '').toLowerCase();
197	$('#errorororo').remove();
198	// nur wenn die Länge mehr oder gleich 3 Zeichen lang ist
199	if (kwd.length >= 3) {
200		// Hier wird der Link zusammengebaut
201		sBasisUrlLink = sBasisUrl + kwd + '.xml';
202		sBasisUrlTitle = 'https://www.ad-hoc-news.de' + sBasisUrl + kwd + '.xml';
203		$('.url-genrsslink').attr('href', sBasisUrlLink);
204		$('.url-permarsslink').html(sBasisUrlTitle);
205		$('#kwd-genrsslink').text(kwd);
206		$('.rssEntryBox').slideDown();
207	}else {
208		$('.rss-form').after('<div id="errorororo" style="clear: both;" class="col-xs-12 col-sm-12 col-md-12 col-lg-12">Bitte mind. 3 Zeichen eingeben<br class="clearer" /></div>');
209		$('.rssEntryBox').slideUp();
210	}
211}
212
213function updateContainer() {
214	var breite = $(window).width();
215	var pathArray = window.location.pathname.split( '/' );
216	pathArray.splice('0', '1');
217	// ab 463 bis 750px Smartphone Landscape
218	// bis 462 == smartphone portrait
219	// ab 751 iPad hoch bis Rest
220	if(breite >= 1182){
221		$('#main_forum').css({'display':'block'});
222		$('#right-box .home_small-news').first().addClass('noDisplay');
223	}else{
224		$('#main_forum').css({'display':'none'});
225		$('#right-box .home_small-news').first().removeClass('noDisplay');
226	}
227	if(breite <= 750){
228//		if(pathArray.length != 0 && pathArray[0] == 'aktienkurse' && pathArray[1] != 'dax'){
229//			window.location.href = "/aktienkurse/dax";
230//		}
231		$('.news-content').removeClass('dotted-border');
232		$('#ul-mobile-navi').find('.wl-li').addClass('noDisplay');
233	}else{
234		$('.news-content').addClass('dotted-border');
235		$('#ul-mobile-navi').find('.wl-li').removeClass('noDisplay');
236	}
237}
238
239function showBanner(){
240	var browserZoomLevel = Math.round(window.devicePixelRatio * 100);
241	var wrapperWidth = $('#wrapper').outerWidth();
242	var windowWidth = $(window).outerWidth();
243	var windowHeight = $(window).outerHeight();
244	var bannerWidth = (windowWidth - wrapperWidth) / 2;
245	var margin = (bannerWidth - 387);
246	var breite = $(window).width();
247
248	$('#skyL_wrapper, #skyR_wrapper').css({'width' : bannerWidth+'px'});
249	$('.skyL_item1, .skyR_item1').css({'height' : windowHeight+'px'});
250	if(100 > browserZoomLevel){
251		$('#skyL_wrapper').css({'margin-left' : margin+'px'});
252	}else{
253		$('#skyL_wrapper').css({'margin-left' : '0px'});
254	}
255
256	if(breite <= 375){
257		$('#billboard_image_mobile').attr('src', '/img/350x90_marketsx.jpg');
258	}
259	if( breite >= 376 && breite <= 479){
260		$('#billboard_image_mobile').attr('src', '/img/468x60_marketsx.jpg');
261	}
262	if(breite >= 480){
263		$('#billboard_image_mobile').attr('src', '/img/728x90_marketsx2.jpg');
264	}
265
266	if(breite <= 1455){
267//		$('#sky-rechts').css({'display':'none', 'max-width':'0px'});
268//		$('#sky-links').css({'display':'inline', 'width':'160px'});
269		$('#sky-links').css({'display':'none', 'width':'0px'});
270		$('#sky-rechts').css({'display':'none', 'max-width':'0px'});
271		$('.content_container').css({'max-width':'1140px',  'overflow-y':'hidden'});
272
273		$('#billBoardT_container').hide();
274		$('#billBoardT_wrapper').css({'height': 'auto'});
275		$('#billboard_image_smaller').show();
276	}else{
277		$('.content_container').css({'max-width':'1460px', 'overflow-y':'visible'});
278		$('#sky-links').css({'display':'inline' });
279		$('#sky-rechts').css({'display':'inline'});
280//		$('#sky-rechts').css({'display':'inline'});
281
282		$('#billboard_image_smaller').hide();
283		$('#billBoardT_wrapper').css({'height': '250px'});
284		$('#billBoardT_container').show();
285	}
286
287	if(breite <= 1295){
288		$('.content_container').css({'max-width':'1140px', 'overflow-y':'hidden'});
289	}
290}

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.