Posts

How to extend the tinymce validation rules for the style tag? -

i have tinymce editor. in editor want enable user use upper cased keyword inside style tag or html element, e.g. [color]. issue editor converts lower case, means system cannot identify later in order replace it. how can prevent editor edit keyword? i tried external_valid_elements, didn't work. extended_valid_elements: "*[style]" the issue solved replacing lower-cased version of keyword upper case before sending back-end.

java - Spring Repository Rest Resource - issue not saving sub objects -

i have been trying restful interface going spring boot have hit problem. when post'ing following json org.hibernate.transientobjectexception exception (please see below) indicates sub-object not being saved. on hand tracing appears json correctly rendered domain objects when save() method (simplejparepository) called doesn't attempt recurse down through sub-objects. intentional? if so, correct approach configuring @repositoryrestresource such save sub-objects? i have minimal spring.boot application happily provide if diagnosis. i have been looking around working example has sub-object (relation) haven't found 1 yet. spring.io example great getting me going have become bit stuck expanding on it. code snippets follow below: json being posted: { "name" : "test sample group", "description" : null, "projectcode" : null, "creator" : "user001", "createddate" : 1395130128971, "...

Android editText does not setText but gives a nullPointerexception in error log -

hey keep getting null pointer exception whenever try settext on edit text maybe can take @ code , tell me i'm doing wrong public class facilitymap extends fragment { public static final string arg_menu_number = "menu_number"; private displayimageoptions options; edittext editgate, editfreeshops, editnature; @override public view oncreateview(layoutinflater inflater, viewgroup container, bundle savedinstancestate) { view rootview = inflater.inflate(r.layout.facility_map, container, false); int = getarguments().getint(arg_menu_number); string titlestring = getresources().getstringarray(r.array.drawer_menu)[i]; getactivity().settitle(titlestring); touchimageview imageview = (touchimageview) rootview.findviewbyid(r.id.imageview2); imageview.setmaxzoom(4); editgate = (edittext) rootview.findviewbyid(r.id.textviewgate); editfreeshops = (edittext) rootview.findviewbyid(r.id.textviewfreeshops); editnature = (editte...

PHP chr() returns diamond question mark from HTML -

i've read lot on subject, since it's quite popular problem, can't find solution... i have html form in it... <html> <head> <meta http-equiv="content-type" content="text/html; charset=iso-8859-1"> <?php header('content-type: text/html; charset=utf-8'); ?> </head> <body> <form method="post" accept-charset="utf-8"> <input type="password" name="pass"> <input type="submit"> </form> </body> </html> ...from password through $_post global , afterwards want split array of ascii values, each of changed standard arithmetic functions (+ / - / * ...) , afterwards changed numbers character ascii table ord function... $password = $_post['pass']; $password = str_split($password); foreach($password $letter) { $letter = ord($letter); ..do algorithmic stuff number get.. $letter = chr($letter); } $pas...

android - Compress video by using FFMPEG -

i tried call c/c++ function in c/c++ file in java file , okay. but don't know how can transfer query string in below c/c++ function` compressing video : ffmpeg -y -i /sdcard/videokit/in.mp4 -strict experimental -s 160x120 -r 25 -aspect 3:4 -vcodec mpeg4 -b 2097152 -ab 48000 -ac 2 -ar 22050 /sdcard/videokit/out.mp4 exactly. what want can compress video using ffmpeg . (i think call via c function in c file) p/s : read many topics, many people issue, no answer satisfied. people know this, please me, thanks, this command converts dozens of api calls in ffmpeg. see option sets what, must read ffmpeg.c file. option use ffmpeg.c, rename main() else, compile program, can call string.

php - Context.io, Response object has protected properties -

i working context.io. able response using php api, however, response object , contains protected properties. response : contextioresponse object ( [headers:protected] => array ( [request] => [response] => ) ) all response object server , need save fields in db. hopefully can give idea

database - Android login Error -

i making login page. in following code, userentered , pswdentered edittext collecting user input. pass userentered parameter in method getsingleentry in database. want method check username in database , return corresponding password back. how method getsingleentry look? boolean diditwork = true; try { string userentered= user.gettext().tostring(); string pswdentered = pswd.gettext().tostring(); string storedpassword=logindb.getsingleentry(userentered); log.d("blahhhhhhhhh", storedpassword); if(pswdentered.equals(storedpassword)) { dialog id=new dialog(login.this); id.settitle("login"); textview tyv=new textview(login.this); tyv.settext("registration successful!"); id.setcontentview(tyv); } else { dialog id=new dialog(login.this); id.settitle...