Posts

javascript - AngularJS: Error when injecting $modal inside a controller that is nested inside of a directive -

we have custom directive generates html around checkbox. uses transclusion inject contents passed within it. looks this: somecheckbox.js angular.module('namespace.directives') .directive('somecheckbox', function() { return { templateurl: 'directives/checkbox.html'; restrict: 'e', transclude: true } }]); directives/checkbox.html <label class="styling" ng-transclude> ... other html </label> we extensively use modals throughout our application , in process of converting bootstrap's angular directive. we've created controller handles particular type of modal appears sporadically throughout out application: angular.module('namespace.controllers').controller('legalmodalcontroller', ['$scope', '$modal', function($scope, $modal) { $scope.showlegalmodal = function(title, legaltextlocation) { $modal.open({ templateurl: 'modals/legal.html',...

wordpress - Using PHP inside a shortcode inside PHP... syntax issue -

ok, i'm ok php not expert. what's correct syntax here? i'm trying pull in advanced custom field data inside php, inside shortcode. i have acf field called: the_sub_field("google_doc_key") <div><?php echo do_shortcode("[gdoc key='https://docs.google.com/spreadsheets/d/"'. the_sub_field("google_doc_key") .'"/edit' gid='0']"); ?></div> somethings not right here... appreciated. <div><?php echo do_shortcode("[gdoc key='https://docs.google.com/spreadsheets/d/'". the_sub_field("google_doc_key") ."'/edit' gid='0']"); ?></div> try that, had ' , " mixed before the_sub_field

java - need to deploy web app on server -

i need write web app scratch date picker allows user select date , queries database according thee input provided user , displays results. deployed on companies web servers(they have various apps on server). however, have no idea start have never written web app before. need local test , prod environment set up. should start, needs included in classpath. how install build tools , configure them?eventually more people work on enhancing app first need set , deployed on prod. written in java. cant comment due low reputation, have post suggestion answer. as jonk posted, site specific code problems, i'd suggest looking few things, might task. choosing various possibilities, tricky thing, , if ware you, ask @ work more common there, problems in development near ;) spring framework quite popular , find plenty tutorials it jsf interesting one, , if choose one, @ so, can answers provided user balusc. 1 said me, if balus has written something, said ;) struts not i...

android - Set Views from TextViews/Layouts? -

is possible set view of view taking data created layout? for example: i have layout file test_layout.xml <textview android:id="@+id/textview1" android:text="textview1" android:background="@color/wisteria" android:layout_width="fill_parent" android:layout_height="wrap_content"/> i want create new view being created out of textview. if creating new view out of drawable do: imageview.setimageresource(r.drawable.shape1); how create new view, including all attributes in textview1? want create new view out of existing textview. textview above acts "template". should setviewbyid ? i hope made myself clear, little hard describe. just use layoutinflater , inflate resource again. layoutinflater inflater = layoutinflater.from(context); view v1 = inflater.inflate(r.layout.test_layout, null); view v2 = inflater.inflate(r.layout.test_layout, null); ...

ios - UIPageViewController displays pages out of order and never calls viewControllerBeforeViewController -

i have uipageviewcontroller , implemented 2 optional methods on data source automatic uipagecontrol. i have following helper methods convert between indices , view controllers. - (uiviewcontroller *)viewcontrollerforindex:(nsinteger)index; - (nsinteger)indexfromviewcontroller:(uiviewcontroller *)viewcontroller; the first method creates new view controller, configures specific index, , stores index in retrievable location (i.e. 1 accessed second method). i instantiate page view controller following code: [pageviewcontroller setviewcontrollers:@[[self viewcontrollerforindex:0]] direction:uipageviewcontrollernavigationdirectionforward animated:no completion:nil]; and here data source methods: - (uiviewcontroller *)pageviewcontroller:(uipageviewcontroller *)pageviewcontroller viewcontrollerbeforeviewcontroller:(uiviewcontroller *)viewcontroller { nsinteger currentindex = [self inde...

html - bootstrap 3.0 responsive 5 images in one row -

i having problem bootstrap 3.0 making 5 images in 1 row , make responsive ? grid system based of 12 , how make 5 images , centered without spaces ? also there away can make when viewed on tablets or smartphones <480 px 2 images per raw? right shows 5 images under each other?? here code: <div class="row"> <div class="col-md-2"> <img class="img-responsive" src="/images/img1.jpg" /> </div> <div class="col-md-2"> <img class="img-responsive" src="/images/img2.jpg" /> </div> <div class="col-md-2"> <img class="img-responsive" src="/images/img3.jpg" /> </div> <div class="col-md-2"> <img class="img-responsive" src="/images/img4.jpg" /> </div> <div class="col-md-2"> <img class="img-responsive" src="/images/img4.jpg...

error with feed excel in drupal -

after installing feeds excel parser , feeds xls, error fatal error: require_once(): failed opening required 'sites/default/libraries/phpexcel/phpexcel/iofactory.php' (include_path='.;c:\xampp\php\pear') in c:\...\sites\all\modules\feeds_xls\feeds_xls.template.inc on line 34