curious1

0

votes
0

answer
4

views

IIS: cshtml pages in an application under a site

On a Windows Server 2016, I have a website with cshtml pages. Under this site, I need to add another site with cshtml pages through 'Add Application' in IIS Manager (version 1607). Let me call this added application 'app' Here is the problem. This link http://example.com/app/index.cshtml produces...
curious1
1

votes
1

answer
4.3k

views

How to easily control spacing height between two paragraphs?

Currently, I am using document.add( Chunk.NEWLINE ); after each paragraph to generate space between two paragraphs. What is the way to generate a spacing of any height I specify? Thanks!
curious1
1

votes
0

answer
54

views

Spring social: authentication with Facebook on machines with a load balancer

My site uses spring social (1.1.6.RELEASE) and spring social facebook (2.0.3.REALEASE) to let users to sign in with their Facebook accounts. Recently, Facebook requires all websites to use HTTPS based URIs for 'Valid OAuth Redirect URIs'. Here is what I have for 'Valid OAuth Redirect URIs' at Faceb...
curious1
0

votes
0

answer
9

views

Got bad characters in scheduled tasks

I use Spring (4.2.9.RELEASE) for a website. It uses Quartz-Scheduler (2.2.1) to run a scheduled task and this task needs to retrieve Chinese strings by using MessageSource. Here is some declaration: WEB-INF/i18n/messages org.quartz-scheduler quartz 2.2.1 The program for the scheduled task has this d...
curious1
1

votes
1

answer
245

views

OpenID Selector in Drupal 7.7 is not working for me

I am using Drupal 7.7 and am hoping to use OpenID Selector (7.x-1.x-dev). I installed Javascript OpenID Selector 1.3 as required. I enabled OpenID 7.7 first and then enabled OpenID Selector (7.x-1.x-dev) and OpenID Selector for Drupal login (7.x-1.x-dev). Now I am able to see a few provider icons....
curious1
1

votes
1

answer
393

views

Spring, JPA, Hibernate: how to prevent an object's timestamp from be changed

I have a Spring + JPA (Hibernate) web application. I have a class which has the following field: private Date updatedTime; @Version @Temporal(TemporalType.TIMESTAMP) public Date getUpdatedTime() { return updatedTime; } public void setUpdatedTime(Date lastUpdatedTime) { this.updatedTime = lastUpdate...
curious1
1

votes
1

answer
336

views

Spring web: how to validate form objects with Spring validator automatically at form submission

I am using Spring validator for form validation. Here is the structure of my code. As you can see, I have to manually call validate in the POST method. Is there any way for me to wire the validator into the form processing without me calling validate()? Please note that my domain object (MyModel) is...
curious1
1

votes
1

answer
139

views

Can org.json.JSONObject produce {“und”:[{“value”:“[email protected]”}]}?

I am trying to use org.json.JSONObject to build the following target json string: {'und':[{'value':'[email protected]'}]} Here is my code: JSONObject und = new JSONObject(); und.accumulate('und', new JSONObject().put('value', '[email protected]')); System.out.println( und.toString() ); But it produces the...
curious1
1

votes
1

answer
252

views

Memory usage of @ModelAttribute and @SessionAttributes

I am doing Spring web application. I have a form and need to load a form object in form GET and POST. I have two ways of loading the object: Load the object via @ModelAttribute annotated on a method Load the object via the form's GET method and annotate the form controller with @SessionAttributes({'...
curious1
1

votes
1

answer
769

views

JqGrid: make the width of rows auto shrink and grow depending on the width of browser viewport?

I am hoping that a JqGrid occupies all the width it is given, and it auto shrinks and grows depending on the width of browser viewport. I am hoping to see the horizontal scroll bar as late as possible when the browser viewport shrinks. I am playing with autowidth and shrinkToFit and combinations of...
curious1
1

votes
1

answer
841

views

A table and its rows gets changed in width when dragging and dropping to reorder its rows

I would like to have a table which allows me to drag and drop to reorder its rows in it. I found this SO post is very helpful: Reorder HTML table rows using drag-and-drop One solution was given in this post and its jsfiddle example is here: http://jsfiddle.net/pmw57/tzYbU/205/ Here is its Javascript...
curious1
1

votes
1

answer
694

views

How to prevent Bootstrap from making the dragged row change in width?

I would like to have a table which allows me to drag and drop to reorder its rows in it. Here is the solution offered by Trevor and the original author. A table and its rows gets changed in width when dragging and dropping to reorder its rows Here is the jsfiddle demo http://jsfiddle.net/trevordowd...
curious1
1

votes
2

answer
217

views

Web Essentials settings error and its setting for LESS

I have installed VS2013 installed on my computer. I also installed Visual Studio 2013 Update 2 RC and Web Essentials 2013 for Update 2 RC successfully. Now when I work on a website project, go to WEBESSENTIALS top menu, and select create solution settings, I get the following error message: Path...
curious1
1

votes
2

answer
204

views

Google search: how can I get as many results as possible (instead of default 10)

My organization has an internal google appliance search server and I am able to get search results in XML via the following form: However, this returns a maximum of 10 search results. I would like to know what hidden input I can add in order to get as many results as possible. To my knowledge, thi...
curious1
1

votes
1

answer
69

views

Spring/Java web: how can I know a request is a form post?

I am doing a Spring website. The website has many pages visitors can get. It also allows visitors to fill and submit a few forms. I would like to use a Spring interceptor (as a central place) to examine each web request from visitors. How can I decide whether a web request is a get request or a for...
curious1
1

votes
1

answer
420

views

Is deleteBy supported in Spring data 1.7.1?

According to Spring doc at http://docs.spring.io/spring-data/jpa/docs/current/reference/html/ It appears it is supported in latest Spring Data (v1.7.1). However, I keep getting the following error in Eclipse: Invalid derived query! No property delete found for type MyClass. MyClass has a field calle...
curious1
1

votes
1

answer
386

views

Replacing OR/AND/NOT filters with bool filter creates a hard-to-understand query with too many levels?

I have the following filter in a filtered query. As seen, it has many OR/AND/NOT filters at different levels. I was advised to replace them with bool filters for performance reasons, and I am going to do that. 'filter' : { 'or' : [ { 'and' : [ { 'range' : { 'start' : { 'lte': 201407292300 } } }, { '...
curious1
1

votes
1

answer
95

views

Google Analytics: how to know the number of clicks on an email link?

I am using Google Analytics in a website. One of the pages has a send-email link as follows: [email protected]com I would like to know the number of clicks on the above link in GA, but cann't seem to find a way myself. Thanks and regards!
curious1
1

votes
2

answer
237

views

Spring MVC: how to prevent Spring from adding commas in numbers for generated strings

On my JSP page, I have the following: In my properties file, I have the following message: label.generate.codes=generate {0} codes. If the numberOfCodes is 1000 or more, here is the final generated string in html: generate 1,000 codes. How can I prevent Spring from adding commas in a number? Put it...
curious1
1

votes
1

answer
1.5k

views

summernote: how to add a “italic” button show it stay next to the bold and underline buttons?

I am new to summernote. I hope to add a 'italic' button next to the bold and underline buttons because it is such a common edit operation. I am unable to find examples of how to do it. Thanks for any help!
curious1
1

votes
1

answer
340

views

Eclipse: how to open a search-found file in a new editor tab?

I constantly use Eclipse's find-in-file feature this way: Search->File->File Search tab. When I get a list of files containing my search string, these files shows in the bottom pane. When I click, in the bottom pane, the line in a file that contains the search string, the file is always opened in th...
curious1
1

votes
1

answer
210

views

Highcharts: some columns are missing when a bar chart changes to a column chart

I am developing a website and using Highcharts. I have a bar/column chart selection. The chart is first displayed in bar chart, and then using the following code switch between the two chart types: Code for changing to bar chart: var chart = code for find the chart object chart.inverted = true; char...
curious1
1

votes
1

answer
398

views

Tomcat + Spring MVC: CSS and Javascript are not loaded in SSL setting

I am using Tomcat (6.0.26) and Spring MVC for a website on Windows 7. I would like to test whether it works on SSL for certain pages or directories. I have a self-assigned SSL certificate (file: .keystore) in C:\Users\Me with the default password 'changeit'. In my Spring's security context, I have t...
curious1
1

votes
1

answer
306

views

How to access the session within doTag of SimpleTagSupport

I have the following simple code: public class MyTag extends SimpleTagSupport { public MyTag() { } public void doTag() throws IOException { //needs to access the session here. how? } } I need to access the session within doTag() to inject a value in the session. I checked all get methods of SimpleTa...
curious1
1

votes
1

answer
49

views

IIS: Odd behavior of modules

I have a few legacy websites and each has a LOT Of static HTML pages. I would like to use IIS module to capture the generated page content and add additional HTML snippets to make it have new header and footer (this is called the decorator pattern). Here is the code I have for the module. The odd th...
curious1
1

votes
1

answer
976

views

FullPage JS: how to “disable” FullPage on smartphones and display sections as a long page?

I am using FullPage JS to display a few sections. On the desktop, it works perfectly. However, Some sections have quite an amount of content. On smartphones, part of the content of these sections is covered. Put it another way, I am only able to see part of the content of these sections when I scrol...
curious1
1

votes
2

answer
146

views

Unable to delete details records through Criteria API

My web app is built on Spring, Spring Data, JPA (Hibernate), and MS SQL server. I have two classes/tables (Master and Detail). Here is how they are associated: Detail: @ManyToOne(fetch = FetchType.LAZY) @JoinColumn(name = 'master') private Master master; Master: @OneToMany(mappedBy = 'master', fetc...
curious1
1

votes
1

answer
271

views

How to access an element inside the iframe in aferShow event?

I am using Fancybox 2.1.4. I would like to access the element inside the iframe in the afterShow event. $('.fancybox').fancybox({ type: 'iframe', afterShow: function() { //need to access element #mydiv } iframe: { preload: true } }); How can I do that? Does preload: true and preload: false has any...
curious1
1

votes
1

answer
2.1k

views

Fancybox 3: how to show the small close button for modal iframe?

I am using Fancybox 3 to display a modal iframe. Here is my code to initialize Fancybox: modal: true, smallBtn: true, iframe: { css: { width : '900px', height: '600px' }, preload: false } If I remove modal: true, I am able to see the small button. However the small button does not show up if I set...
curious1
1

votes
1

answer
375

views

Joda: convert the system date and time to date/time in another zone

I read many posts at SO and tested most of them. None of them is working for me. Here is my code: DateTimeZone fromTimeZone = DateTimeZone.forID('America/New_York'); DateTimeZone toTimeZone = DateTimeZone.forID('US/Central'); Date now = new Date(); DateTime dateTime = new DateTime(now, fro...
curious1
1

votes
1

answer
43

views

Horizontal scroll bar displays at page load for sliding panel

I have a page that consists of multiple sections. One of the middle section needs a sliding panel on the right. However, when the page load, there is a horizontal scroll bar in the browser. Here is the jsfiddle link Here is the HTML: section before the sliding panel show Panel Close T...
curious1
1

votes
1

answer
40

views

Make parallaxed element completely opaque

I have the following HTML structure: This is the CSS in LESS: .parallax{ width: 90%; margin-left: auto; margin-right: auto; } section.back { .triangle { position: relative; img { position: absolute; right:0; top: 0; } } } Before using parallax on the parallax, back just sits immediately below...
curious1
1

votes
1

answer
748

views

Which version of Spring Data supports JPA 2.1?

I googled, but was not able to find this information.
curious1
1

votes
1

answer
41

views

Apache Commons Math: where are the values for SummaryStatistics stored?

I am using Apache Commons Math in my web application. I need to use this class: SummaryStatistics However, I am puzzled by this description: Computes summary statistics for a stream of data values added using the addValue method. The data values are not stored in memory, so this class can be used t...
curious1
1

votes
1

answer
821

views

How to hide series name from tooltip in Highcharts scatter plots for linear regression

I use Highcharts 4.2.3 to create a chart for linear regression. I am following this demo: http://jsfiddle.net/gh/get/library/pure/highcharts/highcharts/tree/master/samples/highcharts/demo/combo-regression/ This is the code in the demo: Highcharts.chart('container', { xAxis: { min: -0.5, max: 5.5 },...
curious1
1

votes
1

answer
1.3k

views

How to run PHP 5.2.13 on Apache 2.4.x?

I have a legacy PHP site, which runs on Apache 2.2 on a Windows server. Now I am asked to upgrade to Apache 2.4. I downloaded Apache 2.4.33 and got it configured, but I always get errors for this line in httpd.conf: LoadModule php5_module 'C:/Tools/php-5.2.13/php5apache2_2.dll' or LoadModule php5_mo...
curious1
1

votes
2

answer
27

views

Page text: disable conversion of HTML links to HTML entities

I have an old Mediawiki site (1.6.x) and I need to upgrade it to 1.31. This site has many pages and many of them have text with html links in the HTML format such as: Text I am able to upgrade its database to 1.31. However, in display, the above html links are converted to
curious1
1

votes
2

answer
2k

views

Does Bootstrap provide linkedin icons and styles?

I am learning Bootstrap and I bought this theme to develop a web app. http://wrapbootstrap.com/preview/WB0C6D0H4 I learned of this website (wrapbootstrap.com) from the book called 'Bootstrap'. In the bootstrap.css coming with this theme, there are lines such as the following: .icon-linkedin:before...
curious1
1

votes
3

answer
3.6k

views

JQuery UI Sortable: how to make items have droppable behavior (ex. hoverClass)?

I am using JQuery UI's drag and drop for a web application. I have the following HTML structure: 1 2 3 and Javscript: $('#list').sortable({containment: 'parent'}); When I drag, move, and drop an item, all items are aligned nicely verticially, which I like it. Now I hope that when I drag and hover...
curious1

View additional