Posts

Showing posts from September, 2015

How i fill combobox items in Radgridview manually using in vb.net -

how fill combobox items in radgridview manually without using datasource in vb.net have radgridview in form.(radgridview1) radgridview1 contained 3 column , column number 3 combobox type. want fill each combobox in column 3 data using code: unp ipe angle box other profile. don't know how it. you can use gridtemplatecolumn following. <telerik:gridtemplatecolumn itemstyle-wrap="true" itemstyle-verticalalign="middle" itemstyle-horizontalalign="center" allowfiltering="false" headerstyle-horizontalalign="center" headerstyle-width="3%" itemstyle-width="3%" headertext="profile"> <itemtemplate> <telerik:radcombobox> <items> <telerik:radcomboboxitem text="unp" value="unp" />

c - Calling a function within a loop -

i trying simple addition function take number x array , add variable i it, iteration variable inside loop. instead of adding each variable individually , producing output of : 3, 2, 7 it produces values of 3, 5, 13. #include <stdio.h> int add(int x[], int y); int main(void) { int i; int a[3] = {3, 1, 5}; for(i=0; i<3; i++) { printf("%d \t", i); printf("%d, %d, equals %d \n", a[i], i, add(a[i], i)); } return 0; } int add(int x[], int y){ return x+y; } try int add(int x, int y){ return x+y; }

vb.net - Unbound DataGridView add row with checkbox error -

this windows forms program. have unbound datagridview control 4 columns; feature id string, parts string, flats string , showonest boolean. columns defined in form designer , boolean column is, indeed, set checkbox tristate set false. the user selects product list box , code executed populate grid grdfeat.rows.clear() = 0 curproduct.lstfeatures.count - 1 (curproduct.lstfeatures(i)) grdfeat.rows.add(.featureid, .parts, .flats, .showonest) end next if allowusertoaddrows false, everthing good. setting allowusertoaddrows true, however, results in following error: formatexception value '' cannot converted type 'boolean'. the error not triggered in code. it's displayed in new tab titled "no source available". it seems pretty clear process adds new editing row trying set checkbox string value, or perhaps null. i'm new (a few months) vb.net, suspect i'm overlooking simple setting somewhere, after several hours of trying

html - Why isn't this media query display none not working? -

i'm trying have mobile-style.css hide background @ 640px. works on chrome not in firefox nor mobile safari? works offline firefox not on server? very strange. <link href="css/style.css" rel="stylesheet" type="text/css" media="all" /> <link href="css/style-mobile.css" rel="stylesheet" type="text/css" media="all" /> <link href="css/muscle-map.css" rel="stylesheet" type="text/css" media="all" /> </head> <body> <div id="muscle-map"> <img id="background" src="crops/00. blank figures.jpg" /> <img id="biceps-a" src="crops/05.a biceps.png" /> <img id="biceps-b" src="crops/05.b biceps.png" /> <img id="obliques" src="crops/04. obliques.png"

Save a file and then open it using javafx -

i have file stored in project directory. make few changes , save using filechooser saved dialog box. after saving want file automatically opened in system. succeeded in saving file not getting how open automatically without user choosing open dialog box. code saving file written below. string input = ""; try { outputstream outstream = null; ipfile = thread.currentthread().getcontextclassloader().getresourceasstream("upgradeworkbench/resources/ip_template.sh"); stage stage = new stage(); stage.settitle("save"); byte[] buffer = null; buffer = new byte[ipfile.available()]; ipfile.read(buffer); filechooser filechooser = new filechooser(); filechooser.setinitialfilename("ip_template"); filechooser.getextensionfilters().addall( new filechooser.extensio

swift - Table view disappears in custom animation -

i wrote following function implement custom animation: func animateit() { println("here") var mainstoryboard = uistoryboard(name: "main", bundle: nil) var anavigationcontroller2 = mainstoryboard.instantiateviewcontrollerwithidentifier("tnavigationcontroller") as! uinavigationcontroller var ainfo = anavigationcontroller2.viewcontrollers[0] as! ainfovc self.view.addsubview(ainfo.view) self.view.bringsubviewtofront(ainfo.view) self.tabbarcontroller?.tabbar.hidden = false uiview.animatewithduration(2.0, animations: { ainfo.view.frame.origin.x += self.view.frame.width }) { (finished) -> void in ainfo.view.removefromsuperview() } } the ' ainfovc ' has table view, disappears when above animation starts. similar functions work other view controller has not table view. thanks in advance.

sql - Transaction With db context in C# -

i trying commit transaction c# context: private testdbentities context =new testdbentities(connectionstring); this.context.connection.open(); system.data.common.dbtransaction transaction = this.context.connection.begintransaction(); dbcommand command = this.context.connection.createcommand(); command.commandtext = "some insert/update query"; command.executenonquery(); transaction.commit(); but error message: "the query syntax not valid. near identifier table_name, line 1, column 8." query seems fine when directly execute directly on sql management studio. there solution? sqlconnection conn = new sqlconnection(); sqlcommand command1 = new sqlcommand(); sqlcommand command2 = new sqlcommand(); sqltransaction trans = conn.begintransaction(); command1.transaction = trans; command2.transaction = trans; try { command1.executenonquery(); command2.

docusignapi - Trouble-shooting slow-loading documents from DocuSign -

Image
a customer representative suggested try posting these questions here. we spent time monitoring issues docusign loading slowly. while slow every time, when slow seemed hang on particular point in process. below screenshot of trace ran in browser , note element took 52 seconds load. when loading slow, seemed hang on particular element. offer reasons why take 52 seconds or more load part? we have other questions: there seems continuous font downloading (2 or 3 meg in size) throughout process of loading page. occurs each time. why , can avoided? why see seattle connection site when of time chicago? we noticed docusign asks permission know our location. location factor document downloaded from? location used in embedded signing processes? thank assistance. unfortunately, without bit more detail not entirely sure can tell why page loading slow. consistent? if same document (perhaps template?) see slowness? as other 3 questions: in doing own test , decrypti

python - Regular Expression in URL Not Working -

i have below url pattern , when trying access saying page not found url(r'^getrequest/(add|edit|delete)/(\d+)/', 'cms_graph.views.test_data', name='cms_data'), i have html page pattern. view.py def test_data(request, data , id): title = "got request %s" %(request.meta['remote_addr']) print request.meta['remote_addr'],data,id if (request.meta['remote_addr'] == '172.20.115.137'): download_data(data, id) context = { "titleofpage" : title } return render(request,'test.html', context) test.html <h1>{{titleofpage}}</h1> where doing wrong?? m trying open http://127.0.0.1:8080/getrequest in order open http://127.0.0.1:8080/getrequest need have specified url pattern r'^getrequest/' (note: , have append_slash setting true, different story). with specified url pattern, of urls below valid (as example): http://127.0.

html - Footer code not showing 3px border on top and not allowing added space on top of text -

i have used new hamburger menu had added top of page. footer not showing 3px border , cannot add space top of text. html5 hamburger menu opens whole page has separate style sheet not effect: <div class="overlay"> <div class="wrap"> <ul class="wrap-nav"> <li><h1>about</h1> <ul> <li><a href="#">athena</a></li> </ul> </li> <li><h1>illustration projects</h1> <ul> <li><a href="#">the knowing</a></li> <li><a href="#">save world</a></li> <li><a href="#">henrietta lacks</a></li> <li><a href="#">the new yorker</a></li> <li><a href="#">myths</a></li> <li><a href="#">drawing laurel</a></li> <li><a href="#">the goonies</a>

sql server - Powershell Script to Start Service if it is Stopped and wait for minute and send an email notification -

i new powershell , in learning stage, have tried create script automate below task. script not working expected. please review , give me on it. my task is, i trying find out sql services (more 1 sql services in multiple servers) in stopped state , trying start it, waiting minute complete service start , verifying service status again. if still stopped state trying sending email setup of people action. could please review below code , correct mistake, tried find unable do #define servers & services variables $servers = gc "e:\bhanu\sqlserver.txt" $services = gc "e:\bhanu\sqlservice.txt" #function call function servicestatus ($servers, $services) { foreach ($server in $servers) { foreach ($service in $services) { $servicestatus = get-service -computername $server -name $service if ($servicestatus.status -eq "stopped") { start-service $service

sql server - SSAS Calculated measure to show values only for specific dimension values -

Image
i have calculated measure in ssas cube, want calculate group of dimension members , rest should zero. in following image want mtdoccupancy dimension work account groups rooms, rest related food should show 0 field. following simple mdx using mtdoccupancy measure ([mtdquantity]/[mtdavailablerooms])*100 you can change measure following: iif( left([account group].[account group].currentmember.member_caption,5) = "rooms" ,([mtdquantity]/[mtdavailablerooms])*100 ,null ) i have guessed dimension/hierarchy combination [account group].[account group]. ... - need change reflect names used in cube.

JQuery UI accordion not working . Main menu items being displayed as submenu items -

http://jsfiddle.net/cxjw6/13/ here fiddle here html code: <div id="sidebar"> <ul class="mainmenu"> <div class="sidebarelementdiv"> <div class="systemstatusnormal"> </div> <li class="sub-handle"><a class="sub-link" href="#!">status</a> <ul class="submenu"> <li class="sub-li"><a class="innermenuitem" href="#!">general</a></li> <li class="sub-li"><a class="innermenuitem" href="#!" id="statusnetwork">network</a></li> <li class="sub-li"><a class="innermenuitem" href="#!">timing</a></li> <li class="sub-li"><a class="innermenuitem" href="#!">gnss&

ios - pickerView different row height -

i have pickerview data loaded website. want set height each row of pickerview. here tried seems pickerview accept's 1 value rows. func pickerview(pickerview: uipickerview, rowheightforcomponent component: int) -> cgfloat { var height: cgfloat = 40 if categories.count != 0 { return heightforview((categories[component].valueforkey("name") as? string)!, font: uifont(name: "helveticaneue-thin", size: pickerfontsize!)!, width: pickerview.frame.width) + 10 } return height + 10 } func heightforview(text: string, font: uifont, width: cgfloat) -> cgfloat { let label:uilabel = uilabel(frame: cgrectmake(0, 0, width, cgfloat.max)) label.numberoflines = 0 label.linebreakmode = nslinebreakmode.bywordwrapping label.font = font label.textalignment = .center label.text = text label.sizetofit() return label.frame.height } for first time categories array empty , rowheightforcomponent uses constant value. when

javascript - multiple errors while momoizing function inside another function -

i have this: function main() { function create_node() { console.log("create_node") (function() { var memo; console.log(memo); function f() { var value; console.log(value); if (memo) { value = memo.clonenode(); console.log("clone node"); console.log(value); } else { var value = document.createelement("div"); var style = ""; value.setattribute("style", style); value.innerhtml = "hello"; console.log("new node"); console.log(value); } return value; } return f; })(); } var colection = []; (var = 0; < 10; i++) { colection.push(create_node()); }; } main(); the problem error (in firefox @ least) while try log "create_node". al

Can I merge two chromium based browsers? -

i have 2 chromium-based browsers each having own benefits, want both of them in one. possible?any help? i need anonimity(epic browser) , torrent download feature( torch browser) in 1 browser, thought merging these 2 idea. getting thier source code , modifying create our own. feasible? thank you.

Is there a option in Activecollab to link a git repository commit to a task comment? -

i added git repository activecollab project. commits shown messages under "sources"- tab. question now: there way link repo commits comments under task linked to? know in default there no way. more interested in work around makes possible. you can "mention" task in commit message using #taskid (or #taskid@projectslug if 1 git repository connected more 1 project). more info can found in active collab documentation: https://help-classic.activecollab.com/books/source/commit-messages-and-tasks.html note there no way add commit comment task, commits related task can found in commits dialog can access options drop-down.

php - How to send the XML encoded data to the Rest API when it has &amp; as it takes the data after "&" as new post parameter? -

i trying send xml data rest php api, xml data has "&" in - when data reaches server data after "&" taken new param. right behaviour? 1 solution send data binary octet-stream curious know if sending data application/xml &amp has behaviour. server side code accept post: if (isset($_post['xmldata'])) { $data = $_post['xmldata']; } else { //see if data coming in file. $data = '' } data sent server via rest client: <envelope> <partyledgername>abc &amp; co</partyledgername> <basicbasepartyname>abc &amp; co</basicbasepartyname> </envelope> data received server looks like: array ( [data] => <envelope> <partyledgername>abc [amp;_co</partyledgername> ______<basicbasepartyname>abc_] => [amp;_co</basicbasepartyname> </envelope>] => )

amazon web services - Error when trying to increase storage on RDS MySQL instance -

i'm trying increase allocated storage 2000gb 2260gb (and iops 6000 7000) on rds mysql instance , i'm getting following error message: null (service: amazonrds; status code: 500; error code: internalfailure; request id: ea593451-3454-11e5-bc38-b7fa8a060cf1) the read replica instance has had it's storage , iops increased, that's not issue. any ideas might causing this? if i've missed key info, please let me know in comments. this error caused fact memchached 1 enabled in options group assigned rds instance trying increase storage for. from aws support engineer: you got in contact unable initiate scale storage rds instance olympus- receiving internal error. after reviewing further on side let know following error being reported: the option 'memcached' cannot deleted instance olympus has read replica has memcached present. this has been brought rds team issue. aware of , working on fix, unfortunately im una

jquery - How to determine if radio buttons are checked? -

this question has answer here: how check radio button jquery? 25 answers i'm trying radio buttons names , check if blank. if 1 blank, form show alert , not submit. if buttons filled go "else" part , see whether answer correct. if correct, show right values in page <div> . it goes "alert" but, if select radio button, not go else part. what doing wrong? $(document).ready(function() { $("#btndel").click(function() { var count = 0; if ($("input[name='ques1']").attr('checked', false) || $("input[name='ques2']").attr('checked', false)) { alert("please fill fields"); } else { //question no 1 if ($("input[name='ques1']").attr('checked', false) || $("input[name='ques2']&quo

mysql - Active Record: eager_load performs unexpected deduplication on results -

i have active record query select objects based on join of table , clause. result might include same object several times , desired behaviour. for example query, 3 results of 2 rows identical. i want eager load association. if use includes , query still produces 3 rows, generated query suboptimal: puts l.count # 3 l = l.includes(:name) puts l.count #3 puts l.to_a.count #3 by forcing use of eager_load , generated query optimized, somehow lose duplicate row: puts l.count # 3 l = l.eager_load(:name) puts l.count # 2 puts l.to_a.count #2 the strange thing is, if manually execute generated query, 3 rows. means active record performs deduplication. why happen , there way work around issue? something noticed during experiments optimal query (and might related) l.count , l.to_a.count not produce same result: puts l.count # 3 l = l.joins(:name).includes(:name) puts l.count # 3 puts l.to_a.count # 2

How can I store required 'base' or 'initial' data for a database (in particular Symfony)? -

i use doctrine migrations bundle track changes in database structure. ensure when i'm deploying / adding new server application that: (a) database schema date (doctrine:migrations:migrate) (b) database contains pre-defined set of data for (b) example roles. want set of roles present. realize possible database migrations, don't idea of mixing schema changes data changes. if use mysql migrations have create equivalent sqlite migration test database. another option i'm aware of data fixtures. reading documentation feeling fixtures more loading test data. if changed role name don't know how updated using fixtures (since either delete data in database before loading or append it). if use append unique keys problem. i'm considering creating sort of command takes set of configuration files , ensures tables in consistent state matching config files - if option exists i'd use of course. what best way handle loading , managing required data database?

bash - Storing into variable a result of boolean expression -

is possible continuously store result of boolean expression variable? example ret=0 each in acollection executesomecommand; # vvv compare stored value against returned value , store again ret=$ret || $?; done; [[ ret = 0 ]] && echo "success" the problem if $? 1 , $ret still contains zero ret=0 echo $ret # --> 0 ret=$ret || 1 echo $ret # --> 0 (should 1) you have grouping/order of operations problem. when do ret=$ret || 1 it first doing ret=$ret , taking result of , doing || 1 ignoring result of that. part of assignment you're doing assigning ret again. what want $ret || 1 part , store result, need parens like ret=$(($ret || 1))

How to add Google-Api-Php-Client library in Laravel 4.2? -

i'm trying build application using google api. however, managed make work in corephp . i'm not able integrate google api php client library in laravel 4.2. can guide me ? google api client available via composer. add laravel run command in base laravel dir composer require google/apiclient now can use google client library in controller or other part of laravel $google_client = new google_client(); $google_client->setapplicationname('your application name'); $google_client->setclientid('your client id'); $google_client->setclientsecret('secret');

java - pass error message from action method to jsp -

this action method containing business logic. want show error message action method in jsp. control goes jsp error message not show up.in jsp have code display error message: <html:errors/> i new struts. in eclipse says saveerrors method deprecated. know how display errors using validate method of bean class extends actionform . public actionforward upload(....) { if(noofcolumns>7) { errors.add(actionerrors.global_error, new actionmessage("error.file.maxcols")); saveerrors(request,errors); return mapping.findforward("uploadvipprocess"); } } the docs explicitly state do: deprecated . use saveerrors(httpservletrequest, actionmessages) instead. this removed after struts 1.2.

Javascript Module Pattern Uncaught Reference Error -

i've been following this tutoral, , when referencing module argument in moduletwo, works fine until comment out module . my understanding double pipes || , empty object {} create empty object in place of module if it's undefined, instead i'm getting error in console. var module = (function () { var privatemethod = function () { // private }; var somemethod = function () { // public }; var anothermethod = function () { // public }; return { somemethod: somemethod, anothermethod: anothermethod }; })(); var moduletwo = (function (module) { module.extension = function () { // method! }; return module; })(module || {}); basically, there’s error in tutorial. 1 way make things work suggested rplantiko, might easier write window.module || {} instead of module || {} . how things work here: accessing non-existent property of object yields undefined . however, referencing variable hasn’t been decl

MapReduce using hadoop streaming via python - Pass a list from mapper to reducer and Read it as a list -

i want pass list value mapper reducer stage.currently, reducer reads list string. there way can make sure python can interpret list. hadoop streaming uses stdin , stdout communication; therefore, coming each subsequent job string. can use kind of delimiter in representation such comma: the, items, in, my, list and split them in reducer: for line in sys.stdin: data = line.split(',') and if want dictionary: import ast line in sys.stdin: dict = ast.literal_eval("{'waffle': 'delicious', 'pancake': 'mediocre'}") there no way know list though because reading standard input stream.

c# - Styling repeat buttons? -

i using following template style repeat buttons text-box's scroll bar: <style x:key="scrollbarlinebutton" targettype="{x:type repeatbutton}"> <setter property="snapstodevicepixels" value="true" /> <setter property="overridesdefaultstyle" value="true" /> <setter property="focusable" value="false" /> <setter property="template"> <setter.value> <controltemplate targettype="{x:type repeatbutton}"> <!--here adjust properties on top , bottom buttons --> <border x:name="border" cornerradius="4,4,0,0" borderthickness="0" > <border.bord

R function to combine lists but prioritize the values in one of them -

i'm trying make function combine multiple lists, between 2 , 4, weed out duplicates , (if possible) prioritize values of 1 of lists. possible? it's better explained code: passopts <- function(in1 = list(), in2 = list(), in3 = list(), in4 = list(){ c(in1, in2, in3, in4) } opts1 <- list(a = 1, b = 2, c = 4) opts2 <- list(a = 1, b = 2, c = 4) opts3 <- list(a = 5, b = 10) combinedopts <- passopts(opts1, opts2, opts3) ideally want possible 'prioritize' list different rest, in case want combinedopts list of a = 5, b = 10, c = 4 . i'm using way set , combine default , user input options. thanks **solved, ended doing realized latest input (i.e. 3 inputs in3) 1 want use default, did follows passopts <- function(in1 = list(), in2 = list(), in3 = list(), in4 = list()){ if(length(in4) != 0){ in4names <- names(in4) rlist <- in4 temp <- c(in1,in2,in3) tempnames <- names(temp) for(i in 1:length(tempnames)){

JWT Verification Failing -

i new jwt tokens. able create , verify jwt in java (using jjwt ) , online using following link http://kjur.github.io/jsjws/tool_jwt.html . but when try create jwt using 1 source , try validate using another, fail. couldn't generate , validate jwt using 2 different sources. tried using http://jwt.io can me understand might wrong? believe should possible create jwt using 1 library , validate using library considering using correct sign algo , secret key. the key input @ http://kjur.github.io/jsjws/tool_jwt.html accepts hex-encoded values. default secret 616161 decodes aaa . verifying generated token @ http://jwt.io/ using aaa secret works.

html - Android browser background-size: cover; issue -

Image
i know there posted questions issue, i'm renewing topic because none of answers working me. problem background-size: cover doesn't seem working in android native browser , chrome android browser, image in beginning displays fullscreen, across whole screen, when scroll, background remains , not moving along screen. code used background-size: cover html, body { height: 100%; min-height: 100%; } body.gallery{ background: url(../img/bg-gallery.jpg) no-repeat center center fixed; -webkit-background-size: cover; -moz-background-size: cover; -o-background-size: cover; background-size: cover; } visual of issue

javascript - Positioning of popup box (md-dialog) behaving strange (Angular Material) -

i working on resource planning tool able scroll horizontally through time (going 2 months , 2 months future). project working angular (angular material), nodejs , mongo. when application first starts or refresh page see current date (highlighted in light blue, see screenshot -> http://gyazo.com/cc3c6c390805e55eb7954d714cc77394 ). have noticed minute click on 1 of buttons triggers md dialog. dialog box automatically jump beginning of calendar or end depending on button click (will jump end if click on settings button)(see screenshot -> http://gyazo.com/c80617e0243914bd61382be402074edd ). my question is, why happening. angular thing , how fix issue show on current view , not scroll way beginning or end

c# - Create command thowrs ORA-01036: illegal variable name/number exception -

i working on fixing sql injection flaw reported tool. our application reading oracle queries xml. query shown below... <commandtext>create user &amp;username identified externally</commandtext> in program, query was modified follows... create user user_05 identified externally i asked add parameter statements avoid sql injection. did similar thing shown below... oraclecommand command = connection.createcommand(); command.commandtext = "create user :username identified externally"; string attrname = "username"; string valuetobeput = "user_05"; command.parameters.add(new oracleparameter(attrname, valuetobeput)); command.executenonquery(); and when tried execute query. failing following exception: {"ora-01036: illegal variable name/number"} can me on this. might doing wrong here? thanks. to prevent exploiting code, should check if entered values save. oracle provides dbms_assert package you. what cr

javascript - EasySlider1.7 - How Do I Get Arrows on a Second Slider To Function? -

i figured out how have 2 sliders on page other posts. final issue have prev & next arrows on second slider don't seem function. i took page on else build first slider , not versed code @ all. i've been using wordpress years. learning go. here page: ginaketchum.com the code in index.html file: <script type="text/javascript" src="js/jquery.js"></script> <script type="text/javascript" src="js/easyslider1.7.js"></script> <script type="text/javascript"> $(document).ready(function(){ $("#slider").easyslider({ auto: true, continuous: true }); $("#slider2").easyslider({ auto: true, continuous: true }); }); </script> the code in easyslider1.7.js: (function($) { $.fn.easyslider = function(options){ // default configuration properties var defaults = { previd: 'prevbtn

php - Laravel - load post with custom id via ajax -

i want load post via ajax when click on post link, how can send post id via ajax? i've got link in blade file: {{ link_to_route($post->type, $post->comments->count() . '&nbsp;' . t('comments'), array('id' => $post->id, 'slug' => $post->slug), array('class' => 'link--to--post')) }} i've got following route definition: route::get('news/{id}-{slug?}', ['as' => 'news', 'uses' => 'newscontroller@show']); and controller action: public function show($id, $slug = null) { $post = $this->news->getbyid($id, 'news'); if ($slug != $post->slug){ return redirect::route('news', ['id' => $post->id, 'slug' => $post->slug]); } event::fire('posts.views', $post); return view::make('post/post', compact('post')); } and i'm trying this: var posttitle = $(

html - Magento base font size -

ok, have developed html page put magento site. it looks fine except fonts small when put magento. i've worked out reason why. basically, sized using ems @ standard 16px size. magento site has line : font: 12px/1.55 arial, helvetica, sans-serif; since of code in div classed .maincontent (with many different divs , font sizes etc within that) there way of increasing base font size 12px 16px within main div? or have individually fix every font-size tag in page? i hope of makes sense! sorry - nevermind! had typo in code - when fixed usual font-size:16px; fixed issue!

javascript - Horizontal dropdown select with images -

i have classic select dropdown, data-bound angular. <select class="form-control" ng-model="category"> <option value="work">work</option> <option value="home">home</option> <option value="practical">practical</option> <option value="no">no category</option> </select> i these dropdown options horizontal images, instead of vertical text. not this: select button work home practical but this: select button work image - home image - practical image i've been playing display: inline-blocks, floats (yikes) , thinking radio buttons considering this question. i'm trying learn angular no jquery please. thank you there limitations on how can style selects. you'd either have pick 1 of numerous stylable select plugins out there or roll own so <div ng-app="app"> <div ng-controller="ctrlr"&g

jquery - FancyBox not working but no JavaScript error -

when preview code in browser , click on image, opens image , doesn't trigger fancybox. doing wrong? <!doctype html> <html> <head> <meta charset="utf-8"> <meta http-equiv="x-ua-compatible" content="ie=edge"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>index</title> <script type="text/x-javascript" src="js/jquery-1.11.2.min.js"></script> <script type="text/x-javascript" src="js/jquery.mousewheel-3.0.6.pack.js"></script> <link rel="stylesheet" href="css/jquery.fancybox.css" type="text/css" media="screen"/> <script type="text/x-javascript" src="js/jquery.fancybox.pack.js"></script> <script type="text/javascript"> $(document).ready(function() { $(".fancybox"

LINQ to Entities does not recognize the method 'Boolean HasFlag(System.Enum)' method, and this method cannot be translated into a store expression -

i have service: //seroiunoiweucroewr ///wercewrwerwerwer //wcererewrwerwer public list<userrolecontract> getrolepagesbyuserid(long plnguserid, displaytype displaytype) { list<userrolecontract> result = new list<userrolecontract>(); using (citicallentities context = new citicallentities()) { try { //var displaylist = utility.getenumdescriptions(typeof(displaytype)).tolist(); //var selectvalue = displaylist.where(i => i.key == (byte) displaytype.windows).firstordefault(); result = (from ouser in context.user join ouserrole in context.userrole on ouser.id equals ouserrole.userid join orolerightspage in context.rolerightspage.where(i => i.isactive == true) on ouserrole.roleid equals orolerightspage.roleid join oapplicationpage in context.applicationpage.where(i => i.isactive == t

jQuery delay function on click -

i'm having trouble trying delay function executing on click event. i have series of links, each one's href being unique youtube video embed url. i'm trying switch source of iframe on page, using 1 of these youtube urls. i'm trying delay switch while page scrolls top. i have created fiddle better illustrates point. i had js function; $(".play-video").click(function(e) { $("html, body").animate({ scrolltop: 0 }, 500); $("#video-frame").attr("src", $(this).attr("href")); }); which worked in both scrolling page , switching iframe, scrolling page while switching iframe source made scroll animation bit jerky isn't ideal. any great. thanks in advance. there's no need mess around setinterval or settimeout . the animate method accepts complete callback run when animation complete. $(".play-video").click(function(e) { $("html, body").animate({ scrolltop: 0

Javascript to PHP and innerHTML deletion -

i implementing script need on 2 issues unable figure out. idea allow create running route , store route database via coordinates. the code follows: (credits to: post 19 here , this fiddle here) <html> <head> <meta name="viewport" content="initial-scale=1.0, user-scalable=no"> <meta charset="utf-8"> <title>drawing tools (b)</title> <script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"></script> <script> window.onload = function() { var latlng = new google.maps.latlng(51.4975941, -0.0803232); var map = new google.maps.map(document.getelementbyid('map'), { center: latlng, zoom: 11, maptypeid: google.maps.maptypeid.roadmap }