text:
Q: WPF Textblock / Set BOLD, ITALIC, UNDERLINE tags direct via Inlines.Add() It is here any solution for direct pasting TextBlock Inlines with HTML markup in C# code like this:
string example = "Here is <Bold>bold</Bold> text, and here is <Italic>italic</Italic>.";
TextBlock.Inlines.Add(example);

A: You could have a look at this project

redpajama_set_name: RedPajamaStackExchange


text:
WYSKIDS: Dave Grippo and the Vermont Student All-Stars
Shakey Graves
Kishi Bashi
Big Bang Bhangra Brass Band
How Sad
The WYSKIDS: Contois School of Music
Abbie Morin
Anais Mitchell + Jefferson Hamer
Brett Hughes and the Honky Tonk Crowd
Moon Hooch
Lee Fields
Saturday, August 23rd, 8/14/14 7:15 pm
How Sad started out in Montreal as the nom de guerre attached to a handful of Harris' personal bedroom recordings, but quickly morphed into a band playing hook-laden synth pop tailored towards live performance. There's an underlying sombre tone to the lyrics, but having those themes juxtaposed with relentlessly energetic music makes for an explosive combination.
About How Sad
Their unpredictable live setup finds them pounding on drums, passionately shouting over sampled beats and screeching with warped guitars. After building a reputation for themselves in their hometown they set off to tour Canada and the U.S. in 2012 playing alongside acts like Purity Ring, Twin Sister, Rich Aucoin, Darwin Deez, and many more. Having played NXNE in Toronto, Sled Island in Calgary, Evolve festival in Nova Scotia, and Pop Montreal and M for Montreal, they released their first E.P. in August 2013.
© 2022 WYSIWYG

redpajama_set_name: RedPajamaCommonCrawl


text:
Q: To remove an item in List I am trying to remove an item in my gcNumber but it is not getting removed. Below is my code. i know i am doing some silly thing but don't know where :(
 var gcn=gcNumber.ToList();
 foreach (var selectGc in gcn)
   {
        var countToRemove = _uow.GetRepository<TripSheetGcDetail>().GetAll().Where(x => x.FkGcId == selectGc.Id && x.IsActive == true).Select(y => y);
        if(countToRemove .Count()>0)
        {
            gcNumber.ToList().Remove(selectGc);
        }
        else
        {
        }

   }
    return gcNumber.ToList();

if my CountToRemove.count()>0 then i want to remove that item in my gcNumber list. Kindly help where i am doing wrong.

A: gcNumber.ToList().Remove(selectGc);

This line creates a new list, which you remove stuff from, then since you don't do anything else (like assign the list any where) throws the modified list away.
I'm guessing what you want to do instead is something like:
gcn.Remove(selectGc);

You also want to modify your foreach so that it isn't looping over something that is getting modified.
foreach(var selectGg in gcNumber)

This will loop over the original thing, allowing you to modify the copy.
And you'll probably want to return gcn, as your return statement just creates another new list based on gcNumber which hasn't been modified.
In summary: .ToList() creates a new list every time, so modifying that list won't do anything to the original.

A: instead of gcNumber.ToList().Remove(selectGc); just do gcNumber.Remove(selectGc);

A: using System;
using System.Collections.Generic;
using System.Linq;

public class Program
{
    public class MyClass
    {
        public string Name {get; set;}
    }

    public static void Main()
    {

        var list = new List<MyClass>();

        list.Add(new MyClass() {Name = "aaa"});
        list.Add(new MyClass() {Name = "bbb"});
        list.Add(new MyClass() {Name = "ccc"});
        list.Add(new MyClass() {Name = "ddd"});

        var indexesToRemove = new List<int>();

        foreach(var item in list)
        {
                if(item.Name == "aaa")
                    indexesToRemove.Add(list.IndexOf(item));
        }

        foreach (var num in indexesToRemove)
            list.RemoveAt(num);

            Console.WriteLine(list.First().Name);

    }
}

Maby it is not the best way to remove items from list but it's clear. You can't remove items form list which is enumerating.


text:
Marketplace focuses on the latest business news both nationally and internationally, the global economy, and wider events linked to the financial markets. It is noted for its accessible coverage of business, economics and personal finance.
District 172: Business owners discuss change on Frankford Avenue
This is part of ongoing coverage in "District 172: The Politics of Change after State Rep. John Perzel," a collaborative effort with Philadelphia Neighborhoods funded by J-Lab.
Change is relative. That seemed to be the message from long-time locals living and working near Frankford Avenue in Mayfair.
The heart of Mayfair, Frankford Avenue has certainly gained a few nail salons and lost a few retail outlets over the years, but not all locals believe these changes to be monumental — or even for the worse.
"People have all these memories of Mayfair as a golden age. It hasn't really changed that much," said Mike "Scoats" Scotese, president of the Mayfair Business Association and owner of Frankford Avenue's Grey Lodge (as well as Fox Chase's Hop Angel Brauhaus).
Joe Veneziale disagreed. "There's no retail on the street anymore," said the owner of Giggles Gifts. "Thirty, 35, 40 years ago, there was nothing but retail stores on the avenue. You could get anything you wanted."
Ed Lloyd, longtime owner of Lloyd Sixsmith, has noticed similar changes over the years. Where there used to be clothing and shoe stores, there are now nail salons and doctor's offices, he said.
Scotese acknowledged that retail has been lost on the street, but said that it's not just a Frankford Avenue problem; it's an everywhere problem.
Bob Domanico, owner of Pat's music on Frankford and Ryan avenues, felt that Frankford Avenue was a good area in terms of retail business. "Some stores would say no, but I think there's a lot of retail business in Mayfair," he said. "We have some good stores on these four or five blocks."
Many locals have also noticed vacant store fronts cropping up over the years.
The vacant stores are victims of the malls, which began to drive businesses out of Frankford Avenue in the 1980s and early 1990s, Lloyd said.
Although some on the avenue, like Lloyd, and Stephen Kanoff, owner of nearby Morry's Dinettes, have definitely noticed more vacancies over the years, others, like Scotese, disagreed.
"There are vacancies, but there's not a crazy number of vacancies. You really can't find a lot of vacant store fronts around here," he said. "Frankford Avenue is holding up very well."
Many were divided on whether or not chain stores, like Walgreens, the Family Dollar and Dollar Tree, have taken over Frankford Avenue.
Kanoff said he was not happy with what he considered big business taking over small "ma and pop" shops in the last two decades. "How many butchers and shoe makers and tailors have all gone out of because of the corporations?" he said. "And that's the way it is."
Others had a more sunny assessment of chains on the street.
"We've lost a pharmacy or two and gained a Walgreens," said Scotese. But "there always have been chain stores on the avenue. I think we have fewer than normal."
Scotese and fellow Business Association member, Antoniette Montgomery, owner of Torresdale Flowers on Frankford Avenue near Aldine Street, would welcome the chain stores if they brought more people onto the street to shop and check out the local bars and restaurants.
"It's a shame we can't get bigger stores in the area — like a Barnes and Noble — that would attract the area a little bit better," said Montgomery, who has lived in the neighborhood for more than 20 years.
"I don't have a problem with the Family Dollar," she added. "The more problems we have are with the check cashing places showing up because some of them end up being pawn shops. Once people start seeing that they get scared."
Entertainment on the street was another topic for debate.
Kelli Smelser, an employee of Penn Hardware, who's lived in neighboring Tacony for more than 15 years, felt there used to be more to do on the street.
She recalled the Concord Roller Rink, on Princeton and Frankford avenues, which shut down in 1985, and is now a public storage facility. There were also four movie theaters — the Mayfair, the Holme, the Merben and the Devon — on Frankford Avenue that have since closed.
Scotese pointed out that although the avenue's roller skating rink and single-screen movie theaters have shut down, these old-fashioned entertainment venues are pretty much obsolete everywhere.
He said it was pointless to "worry about what's not on the avenue anymore that isn't going to survive anyway."
Despite the loss of some entertainment spots on Frankford Avenue, there is still plenty to do on the street, Scotese said.
The Business Association hosts several events like the Mayfair-Holmesburg Thanksgiving Day parade, an annual Christmas tree lighting and the Mayfair May Fair and Fallen Heroes 5K run each May.
There is also entertainment on the avenue everyday, Scotese said.
"Mayfair's always had a very lively bar scene and we still do," he said. "There are a lot of restaurants, and we are starting to see some really good restaurants open up."
Saleem Ahmed and Jennifer Klimowicz are students reporting for Philadelphia Neighborhoods, the publication of Temple University's Multimedia Urban Reporting Lab.
172nd District residents eligible for service award
Ideas for the Columbia Avenue Connector project
Zoning code versus Northeast politics


FASTEST TITLE LOANS ALAMOGORDO NM HAS TO OFFER!
Were you recently hit with an unexpected expense that you aren't sure how to take care of? Or maybe you are short on cash this month, unable to pay for rent or bills? Whatever the case might be, New Mexico Title Loans, Inc. is here to help. We offer the Alamogordo title loans that could up to $10,000 of emergency cash in your pocket today, regardless of your credit history. You can find our store located at 415 South White Sands Boulevard in Alamogordo, where we are across the street from Papa John's Pizza and the Hi-D-Ho Drive In, between Wendy's and Arby's.
Before you head to our store, you will want to fill out our short online request form, which you can find right on this page. Once that has been filled out, you can expect to hear back shortly after from a friendly store representative. They will have reviewed your form, and will take the time to explain the title loan process to you and answer any questions that you might have. They will also make sure that you have the simple required items listed below, which you will want to make sure to bring with you when visiting our store.
After your call is over all you need to do is gather those simple required items and drive them over to our store in the vehicle you plan to use for your title loan. When you arrive, a loan specialist will have your paperwork ready to go, which you can fill that out as a manager performs an inspection of your vehicle to establish the maximum amount of cash you could qualify for. After that, you could get the emergency cash you need within minutes, and you even get to continue driving your vehicle while you repay your loan.
So get started now and let New Mexico Title Loans, Inc. help with your emergency cash needs today!


text:
Mary Frances Early College of Education
Events Directory Internal Resources Search Make A Gift
All Concentrations
All Degree Programs
Non–Degree Programs
Placements, Student Teaching, and Clinical Practice
Want to Teach?
StudyAway
Educator Preparation Resources
Visit the College
Graduation Convocation
Communication Sciences and Special Education
Counseling and Human Development Services
Educational Theory and Practice
Language and Literacy Education
Lifelong Education, Administration, and Policy
Mathematics, Science, and Social Studies Education
Workforce Education and Instructional Technology
MAT in Workforce Education (Marketing Education)
Deadline To Apply
The MAT in Workforce Education program is designed for students who wish to earn initial certification in a career and technical education (CTE) instructional field at an advanced level (T-5).
The Marketing Education area of emphasis is for those who may have a professional background in fields such as Marketing and management, Marketing and communications, Fashion Merchandising, Sports and Entertainment Marketing, or Hospitality, Trade, and Tourism Marketing.
Our program combines your professional specialization and expertise with promising teaching practices, leading to competency in:
Managing career and technical education programs in Georgia P-12 schools
Designing and developing both content and skill-based instruction
Utilizing workable research strategies in your own classroom and school
Cultivating students' work ethic, communication skills, and capacity for innovation
Leads to initial teacher certification in Marketing Education (6-12)
One of the top workforce education programs in the country
Flagship workforce development program in Georgia
Produces leaders in industry knowledge as well as current international trends
Prepares graduates to proactively identify workforce trends
Our faculty have developed a research-based model that focuses on career development, work ethic, and innovation to strategically prepare a global workforce who can successfully navigate work, even in jobs that do not exist at the time education and training take place.
The MAT in Workforce Education requires a minimum of 48 credit hours of coursework, divided into four categories:
Core professional education (24 hours)
Education research (3 hours)
Teaching internship (12 hours)
Certification area of emphasis (9+ hours, depending on academic background)
Download a Sample Curriculum
Read FAQs About the Workforce Education Programs
Teacher candidates must (1) apply for a GaPSC Pre-Service Certificate prior to beginning field experience and (2) complete several assessments prior to certification.
Part 1: Apply to the University of Georgia
The Graduate School handles admission for all graduate programs at the University of Georgia, including those in the College of Education. The Graduate School website contains important details about the application process, orientation, and many other useful links to guide you through the process of attending UGA at the graduate level.
Start A Graduate School Application
Part 2: Apply to the MAT in Workforce Education (Marketing Education)
To qualify for admission, students must have earned an undergraduate degree from a fully accredited college or university. A minimum of a 3.0 GPA in their undergraduate degree is preferred.
In the Graduate School application, students must submit:
Official transcripts from all colleges and universities attended
July 1 (Fall)
November 15 (Spring)
May 1 (Summer)
Log Into Existing Application
Please use our online form if you have any questions for the department. Please be as specific as possible so that we may quickly assist you.
2020-2021 Program Assessment
The College's programs are taught by dedicated faculty who are experts in a range of areas and are passionate about helping students succeed both in their programs and professionally.
Most graduate students at UGA are not assigned to a faculty advisor until after admittance. A close working relationship with your advisor is paramount to progressing through your program of study.
Almost all in-state students begin their studies at UGA paying limited tuition or fees. Please note that these amounts are subject to change and are meant to give prospective students an idea of the costs associated with a degree at the University of Georgia College of Education.
Students may qualify for a variety of assistantships, scholarships, and other financial awards to help offset the cost of tuition, housing, and other expenses.
Tuition Rates Browse Financial Aid
Our students have a range of opportunities available outside the classroom as well, from professional organizations, experiential learning, clubs and other non-academic experiences.
See for yourself how much UGA College of Education has to offer! Schedule a tour of campus to learn more about the UGA student experience.
Help Desk/Tech Support
G3 Aderhold Hall
110 Carlton Street
UGA Course Bulletin
UGA Financial Aid
UGA International Education
UGA Graduate School
Submit a Student Complaint
#UGA onFacebookTwitterInstagramSnapchatYouTubeLinkedIn


How do you know NEST Student Management System?
What did you use NEST Student Management System for?
When did you first use NEST Student Management System?
How long did you work for NEST Student Management System?


From Verona or Venice Airport, we propose an exclusive transfer in the city of Bassano del Grappa: the heart of Veneto Region, where art, history and culture is perceived while walking through the streets and squares of the city, whose symbol is the wooden Ponte Vecchio designed by the famous architect Andrea Palladio. An hour away from Venice, Verona, Padua and Treviso, Bassano is the ideal starting point to discover the historical cities of Veneto, and the small medieval villages, castles, villas and traditions of a plentiful land of worldwide leading Made in Italy products.
Once arrived, we offer a privileged accommodation in an elegant 18th century villa just outside the ancient walls of the city, which is nowadays a prestigiour hotel with an unexpected restaurant.
If arriving in the morning, you will immediately discover the elegant peculiarities of this charming town by walking in the historic center. Whereas, if arriving in the evening, you can taste the typical aperitif at the Ponte Vecchio, a traditional meeting place for tourists and local people to taste the classic drink of the city, the "mezzo e mezzo".
Dinner will be at the prestigious restaurant of the Hotel, where the chef Alex serves local dishes, yet presented in a very artistic and creative way.
After breakfast, we propose a guided walking tour of Bassano to discover the medieval history of the city, the Ezzelini's history, one of the events of the First World War, the great artists of the city Jacopo da Ponte and Andrea Palladio and so forth.
After the tour, we offer a full immersion in the local gastronomy, followed by a cooking class with a cute chef who will teach you particular recipes and kitchen secrets of the most traditional dishes of Veneto. In the end, you can taste the dishes you have prepared.
In the afternoon, you can relax by walking around the city to discover the best shops in the center of Bassano.
We will continue the day exploring Asolo, the city of 100 Horizons with a panoramic terrace on the hills among the ten most beautiful towns in Italy. Then, you can walk in the center to sip the aperitif at the historic Caffè or at the Enoteca on the porch of Browning Street. Finally, you can continue to enjoy a tasty and excellent dinner in a charming Old Town restaurant which serves excellent traditional cuisine.
The third day is reserved for shopping: accompanied by the romance of Romeo and Juliet, this is a day to do an amazing shopping tour with the personal shopper Ekaterina Pitti through the streets of Verona where the biggest names of Italian fashion, such as Trussardi or Versace, stand out. Then you can enjoy a frivolous lunch under the sun in Piazza delle Erbe or in a typical restaurant or osteria of the historic center suggested by us. In the afternoon, after visiting Verona, we propose a stop at the outlet of Bottega Veneta, where you can find a wide range of products of the great Italian fashion brand with certainly affordable prices! Then, back to Bassano, you can enjoy dinner in a typical restaurant of the Old Town, to finally return at the hotel.
In the morning, we offer the experience of tasting fragrances in the atelier of Claudia Scattolini, a fragrance designer author of unique fragrances to wear. Italian taste and elegance, combined with a good measure of French savoir-faire, creates the extraordinary formula made by the fragrance designer who creates tailored perfumes for special people. Among its wonderful collection, you can find delicate or luxury fragrances, created from noble and refined materials. Or you can ask for the exclusive experience of giving life to your unique fragrance that expresses your person, made on the psychological tests and analysis of the personality.
At the end of this intense experience, after a slight free lunch in the center, the tour continue to Stra, in the Brenta Riviera, to discover the Shoe Museum Rossimoda, founded by the President of Calzaturificio Rossi, a manufacturer of luxury women's shoes who possesses licenses by high fashion brands of the highest level of quality and international importance. Here you will discover the collections of names that are pillars of fashion footwear such as Vera Wang, Calvin Klein, Kenzo, Emilio Pucci, Fendi, Ungaro, Dior, Yves Saint Laurent. These collections are displayed in an historic Villa on the Brenta Riviera: an elegant blend of history and fashion.
In the evening, we propose a transfer to Venice, to have dinner in a typical bacaro of the historic center, a place outside the usual tourist routes where you will discover the charm of Venice by night in a authentically Venetian local.
Today you will discover the secrets of the bubbles of Prosecco in the stunning landscape of the hills of Valdobbiadene, first traveling through the vineyards and ancient villages that are in the proximity, then arriving in a cellar that is the symbol of the growth of this wine, in the context of a Palladian style villa of the 16th century. Indeed, the cultural heritage of Treviso land is the Villa, a successful example of the harmony between art and agriculture that characterized the Venetian landscape of the past centuries. The dinner, with a wine tasting and a combined menu of recipes from the Treviso area, will be at the Locanda, a traditional farmhouse of the Veneto region of '900.
This will be the conclusion of a journey in the discovery of a less known but equally charming part of Veneto, a region full of tradition and ancient stories, companies and products to discover and to bring home with you.
Transfer to the airport and departure of the Ladies Guests.
5 night stay in in an exclusive hotel in Bassano del Grappa. 4 dinners at exclusive restaurants, as planned, guided tour of Bassano del Grappa, Asolo, the Shoe Museum, Cooking Class, fragrance taste, wine taste in the cellar of Prosecco, excursions as described, guide and transfer to the entire tour included.
Tour of 5 nights and six days in the heart of Veneto. For those who enjoy knowing the details of this region.


Home » Pediatrics » Is it time to ditch your deodorant?
Is it time to give up your go-to deodorant? For many people, the "go without" choice isn't an option, but there are alternatives to consider.
Most traditional deodorant products contain aluminum and, right now, we don't have enough information to confirm that the amount of this ingredient in these products is harmful to your health. However, if you are concerned, there are an increasing number of options with more natural ingredients that could provide more peace of mind.
If you choose to switch, here are a few things to know. First, underarms produce sweat, which is unfortunately unpleasant smelling, as part of the body's natural ventilation process. One of the most effective chemicals for fighting sweat and odor is aluminum, which inhibits perspiration.
The problem is that the skin under the arms is quite sensitive. Applying heavy chemicals to the area can cause skin irritations such as a rash or itching. Also, because the skin is quite thin, it is possible that the lymphatic system (which also resides under the arms) could be impacted by an allergic reaction to an ingredient in the deodorant. In this case, the immune system could respond and the nearby lymph nodes might swell in response.
While the jury is still out, some studies suggest a tie between aluminum products and an increased risk for cancer, particularly breast cancer. In one study, cancer patients had significantly higher levels of aluminum in their breast tissue, and researchers concluded that the "reasons for the high levels of aluminum in fluid aspirated from the breast remain unknown but it is possible that exposure to aluminum-based antiperspirant salts in the adjacent underarm area could be the cause." (Journal of Applied Toxicology, April 2011). An additional study was not conclusive in showing a link between frequent underarm shaving and antiperspirant use among cancer survivors who reported using the products and shaving at an early age. (European Journal of Cancer, 2003).
Parabens, which are used to kill bacteria in water-based solutions. However, studies have shown that parabens mimic estrogen, thereby disrupting hormone function and increasing cancer risk.
Phthalates, which are endocrine disruptors that can interfere with your hormone system and have been linked to hormone imbalance, diabetes, obesity, cancer, developmental disabilities and even infertility.
Propylene glycol, which is actually an ingredient in antifreeze. This additive is found in many personal care products and is used as a penetration enhancer, meaning that it helps other chemicals go deeper into the skin, carrying the risk of immuno-toxicity and allergies.
Formaldehyde, which is also a carcinogen, or a substance capable of causing cancer.
Fortunately, there are many new options for natural deodorants. Some contain coconut oil, which helps prevent the growth of unpleasant smelling bacteria and is good for people with sensitive skin. Or, you could make your own, as in the option shown below.
Finding the best option may take time, as people react to natural products differently. Some may find that the more natural products aren't as effective as their old standbys, so it helps to invest in a few options and experiment with what works best.
Besides minimizing your risk for health concerns, it's also been found that natural products are better in preventing skin irritation and helping unclog pores.
People with skin issues should also talk to a dermatologist to find the right combination for them. We all sweat, but selecting the right deodorant is obviously a very personal issue. Since using deodorant is a daily routine, it makes sense to find the products that are both effective and help allay your concerns about exposure to potentially problematic ingredients.
To find a Swedish dermatologist in your area, visit our provider directory.


text:
Q: Using flexbox with wrap and align-content: center overflows the parent outside scroll area I want to use flexbox to position div children inside a div container.
I want them centered inside the container so I use justify-content: center; and align-items: center;. I also want the children to wrap if there are too many to display side by side, so I use flex-wrap: wrap; and align-content: center;. Everything works as expected as long as all content can be fit inside the container.
If the window is really small however the content is overflowing the container and it does show scrollbars, but the first child is still outside the scroll area. This does not happen when align-content is anything other than center.
It happens in safari, chrome and firefox so I assume it is not a bug.
Any idea what causes this and how to fix it?
I also made a codepen to illustrate this (make the browser window as small as possible and scroll to the top to see the first child clipped from view):
http://codepen.io/SubHero/pen/bpZXzm
HTML:

Child1

Child2

Child3

Child4

CSS:
* {
  margin: 0;
  padding: 0;
}

html, body {
  width: 100%;
  height: 100%;
}

body {
  display: flex;
}

.parent {
  display: flex;
  flex-grow: 1;
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  align-content: center;
}

.child {
  width: 300px;
  height: 200px;
  margin: 20px;
  background-color: #4caf50;
}

A: Removing
align-content: center;

fixes the problem.
When the align-content property is set to center, it places flex items in such a way that their centers are all at the same place vertically. However, when the window is small, the flexbox wraps all elements underneath each other, which means the flex items are centered vertically, and the first child at the top falls out of view. The reason the child at the bottom doesn't do so, is because webpages automatically extend vertically to accomodate the extra height.


Right Location to Get Essay Facilitate! We have been happy to welcome you with the first-class paper writing program!
stunning high quality of papers, which we are truly proud of. This is certainly what distinguishes us from many people and will make our company the chief inside the industry of college essay crafting. Aquiring a serious volume of returned customers, we honestly think that it is all about the top quality for the essay composing assistance we produce. And this is definitely the truly number one explanation why you could potentially trust us together with your college or university assignment.
What you get our site is really an opportunity to decide on your very own author and purchase personalized paper for fair pricing. We supply top quality ordinary papers inside of your charge variety. You will not regret paying your money and on top of that you may be amazed how successfully they may be put into use when doing work with our team.
Control Your Tailor made Essay Creating Approach!
We know how major educational papers are and that the large number of the grades depend upon them. Our workforce is striving to make our via internet essay crafting provider as much consumer oriented as feasible. That is why we offer you when using the chance to get comprehensive control above the progress of your respective get. Keep track of your get anywhere you are feeling like and be mindful within the circumstances. Go away your problems driving and place an finish to nervous waiting during the paper producing operation. Participate in forming your paper and direct your author with comments to get accurately everything you require. Experience free of charge to check with for revisions as a large number of days while you want totally demand free of charge and make your personalized paper merely Perfect.
Why Will ideally You employ Our greatest Essay Crafting Company?
In principle, all students can profit from producing their own personal educational initiatives. In exercise, which is solely hopeless. Why would you probability missing a deadline or publishing below-average subject material as soon as you have skilled professional writers on the side? Rather then expending days over a very simple essay, it is possible to delegate it to our writers and make use of your time more productively. You will continue to acquire knowledge and abilities, considering that you?ll hold the chance to look at how specialist writers tailor your papers.
Good quality often is the essential characteristic that sets us besides other essay creating expert services. Some establishments could very well cost you a lower price for paraphrased or pre-written papers. This substandard subject matter will not be customized to your guidelines and it will not satisfy your professor?s demands. You are aware of exactly what the penalties for plagiarism are. In case you elect to job because of the ninjas, your papers can be published by proficient, degreed indigenous English speakers who really know what educational composing is about.
All writers within our team keep MA or PhD levels. Additionally they have go through in finishing various tutorial tasks on subject areas that belong for their discipline of examine. Once you buy an essay at our internet site, we ensure that you are going to get 100% primary get the job done dependant upon in-depth examine and guided by your guidance.
What's going to You can get in the Easiest Creating Support?
Every single piece of articles and other content we supply is to be customized from scratch. The process is custom-made as stated by the precise standards from the customer, so you can rest confident that the trainer won?t notice everything suspicious. Ninjas are invisible, remember? No one will at any time identify out that someone else wrote a paper in your case. Once we get your purchase, we're going to assign it into a trusted writer with relevant experience. He/she will adopt your instructions and tailor a plagiarism-free piece formatted and structured based on the tutorial standards you show.
One of the best element is superior quality arrives at highly affordable price ranges at our web-site! Moreover, all our shoppers get one-time and lifelong discount rates that make the ultimate prices more cost-effective.
We understand how vital your deadlines are. Even the most impressive paper will not come up with a change in the event you really don't submit it punctually. That?s why we guarantee to deliver all jobs because of the deadlines our patrons set. We'll also take care of you with effective policies that include prompt revisions upon request, truthful refunds, and supreme degree of confidentiality. If you should have grievances with regard to the assignment you receive, only get in contact with our 24/7 client assistance product and we're going to handle the problem while not delays.
You will find no reason to squander even more time. Click the Order Now button and reward with the aid of our knowledgeable writers.


Thanks, everyone, for the responses. Modular smart array command line interface user guide 52 pages. The XP devices hdisk0, hdisk7 and hdisk8 are seen down one fiber channel adapter port and one port out of the XP itself – hence only seeing those hdisk devices once but if we masked them down multiple XP ports, we'd see multiple hdisk devices for each of those luns without the XP ODM entries. AIX Forum Log in to participate. Page 50 Page 51 – Configuring non-Windows application serv Indicates cabling connections to disk enclosures.
Don't show me this message again. To print the manual completely, please, download it. Got it, continue to print.
Page 55 – Creating volume groups on a virtual disk Hewlett-packard storageworks arrays family guide 16 pages. Comments to this Manuals Your Name.
I think you need filesets like: We're working with HP, but thus far we haven't found anyone there that has a clue yet.
Figure 29 Cabling the controller to front end component—direct Fibre Channel to servers with. Hp storageworks modular disk system maintenance and service guideseptember 58 pages. Page 47 – Configuring management servers using HP Continuous access synchronous for mainframe systems pages. Figure 27 Cabling the controller to front end components – direct Fibre Channel to servers with.
Hp storageworks c extreme data storage system user guidenovember 50 pages. LED status indicators for cabling connections to disk enclosures. Figure 26 Cabling the controller to front end components – direct Fibre Channel to servers with.
Don't show hwv300 this message again.
Hp storageworks g2 modular smart array reference guidemay pages. I just hsvv300 HP's site and didn't find the ODM defs but they are probably available if you have a login. Page 20 – Turn on power Page 21 – Verify the operating status of the disk Enter text from picture: Thanks for the reply.
Unanswered question This question has not been answered yet. Modular smart array command line interface user jp 52 pages. Answered question This question has been answered. Table of Contents Add to my manuals Add.
Page 84 – Cabling the controller to front end comp Page 22 – Verify the operating status of the Fibre Comments to this Manuals Your Name. Took nearly the entire day hsv30 get them, but final delayed success is better than no progress at all Page of 40 Go. Page 83 – Connecting Fibre Channel cables to the E This is the accepted answer. The XP devices hdisk0, hdisk7 and hdisk8 are seen down one fiber channel adapter port and one port out of the XP itself – hence only seeing those hdisk devices once but if we masked them down multiple XP ports, we'd see multiple hdisk devices for each of those luns without the XP ODM entries.


The Houston Methodist Center for Performing Arts Medicine is thrilled to present the Margaret Alkek Williams Crain Garden Performance Series at Houston Methodist Hospital. The Crain Garden Performance Series features performances by individuals and members of different arts groups.
THURSDAY, APRIL 11 | 11:00 A.M. - MCGOVERN MEDICAL SCHOOL ART AND MUSIC IN PATIENT CARE Medical student musicians from the McGovern Medical School will present a diverse program of music for piano, violin and voice by such composers and songwriters as Antonín Dvořák, Astor Piazzolla, Édouard Lalo and John Legend.
TUESDAY, APRIL 16 | 11:00 A.M. - H-TOWN 5 A brass quintet featuring some of Houston's finest musicians, H-Town 5 performs music from early jazz to show tunes to classical favorites. This performance will include performances of music by Vivaldi, Duke Ellington, Bach and more and will be a part of the Houston Methodist Volunteer Services Appreciation Lunch.
WEDNESDAY, APRIL 17 | 11:00 A.M. - MUD TURTLE QUINTET Led by guitarist Marc Rosenberg, the Mud Turtle Quintet will present a concert of jazz-influenced compositions for guitar and string quartet.
THURSDAY, APRIL 18 | 12:30 P.M. - HOUSTON METHODIST SINGERS The employee choir of Houston Methodist will present a concert of inspirational songs for Holy Week including traditional African American spirituals.
MONDAY, APRIL 22 | 1:00 P.M. -SHEPHERD SCHOOL STUDENTS PLAY MOZART String students from Rice University's Shepherd School of Music will present performance of Mozart's String Quintet in C major, K. 515.
TUESDAY, APRIL 23 | 12:00 P.M. - WINDSYNC Music by Ginastera, Dvorak, and a newly commissioned wind quintet Apollo by Chicago-based composer Marc Mellits which celebrates the 50th anniversary of the Apollo 11 Moon landing mission. Exploring ideas of home and Houston as "Space City", WindSync's program features composers interested in capturing the authentic sound of people and places.
WEDNESDAY, APRIL 24 | 7:15 P.M. - HOUSTON CONCERT BAND A volunteer organization comprising over sixty men and women in the Houston area who are dedicated to making a unique musical and cultural contribution to our community.
TUESDAY, APRIL 30 | 12:00 P.M. - MI OU LEE AND KAMI GHAVI HELM Presenting "Music That We Love to Play", an engaging performance of violin and piano duo works as well as solo violin and solo piano works. The selections include works by Beethoven, J.S. Bach, Brahms and Stravinsky.
All performances are free, open to the public and held in the Crain Garden of Houston Methodist Hospital (unless otherwise noted), 6565 Fannin Street. Parking is available next door in TMC Garage #1 and valet parking is available directly in front of the hospital. The Metro Rail Dryden/TMC Station is also located directly in front of the hospital.
Download a copy of the guide for performing as part of the Margaret Alkek Williams Crain Garden Performance Series.
Any Houston Methodist employee who makes a purchase from the Fannin Street Starbucks in the main lobby during the concert will receive a 15% discount. Please show your employee badge at the time of purchase.
Learn more about Houston Methodist's Center for Performing Arts Medicine.
Interested in performing as part of the Margaret Alkek Williams Crain Garden Performance Series at Houston Methodist Hospital? Request the opportunity here.


I am a broker for two large companies. I need a programmer to develope a program for them. I have the program running on a dialogic system now. The program is very basic for what I do.
send email if you can handle this project.


I have been living in Singapore for three years and have not regretted my decision for a second. Partly, this is because Singapore is my fourth country of residence and I have no attachment to any group, apart from those with whom I feel psychological affinity.
Moving to a different country might not be for everyone, but it can help you maximize your living conditions and feel freer by escaping increasingly controlling and restrictive governments.
If you live in the Western world, consider the demographics. When you couple the increasing sense of entitlements and Social Security payments with decreasing tax revenues and decreasing growth-rates… it makes it extremely important to secure your hard-earned wealth from being taxed away by your government.
It is conceivable they might even at some point make it impossible for you to leave, thus making you a complete tax slave.
By keeping a couple of passports and living in a third country (and using cash wherever possible), one can design a life of anonymity and freedom – all legally.
If you want to make your life and, at least in some sense, your money, your own… you have no choice but to be "paranoid". Interestingly, by being paranoid and then acting to internationalize yourself, you can eliminate your paranoia. Then you need not fear becoming a tax slave. Instead, wherever you go, you will be welcomed as a tourist and seen as a contributor to the local economy.
As I write this, most of my wealth is located in countries with which I have had no tax or residential connection for the last five years. And the best part is… they don't care. These countries are all grateful for my investments and know full well that, having no jurisdiction over me, if they create problems for me my capital would leave in seconds.
I live in Singapore but keep minimal wealth here. Singapore does not tax your wealth and hence does not care where you keep your capital.
But why give them a chance to trouble you? The next generation of Singaporeans might be entitlement-oriented (and they are), and therefore I want to be in a position to leave again when the time comes.
If I am fortunate, that time may never come, as its tax regime is its core competency and main attraction.
It's a good question. Why would I choose to live in a country that is constantly ridiculed for the use of caning as a punishment, and that lacks freedom of speech?
Singapore's reputation makes people question if they must sacrifice their freedom in order to save taxes.
Allow me to address each of these issues.
First, it is a myth that democracies (read: dictatorship of the masses) by definition offer more benevolent living conditions. In my experience, democracies have seeds of self-destruction. Singapore, on the other hand, is more like a family-run corporation – a political system I prefer over democracy.
Here I don't see any busybodies around. Bureaucratic interferences in your life are minimal. They focus on governance and they do it relatively well. They are nowhere close to an ideal government, but compared to what you get elsewhere, Singapore is a treat.
Second, while it is true that they do have tough drug and gun laws, they are effective. Singapore is one of the safest cities on the planet and a young girl here can feel comfortable walking by herself just about anywhere, even late at night. Since I have no reason to own a gun nor do I consume drugs, Singapore fits in my life design plan just fine.
Third, while this may sound quite shocking, to me, caning as a mode of punishment looks quite appropriate in many situations.
For example, I recently saw a video of three teenagers beating an old man for fun in the U.S. The teenagers likely went unpunished. I would prefer that they had to slog for several years to make monetary retribution to the old man. But lacking that, I certainly think caning is a better form of punishment than letting the culprits go.
Lastly, freedom of speech is limited only in the arena of politics. Quite honestly, if more freedom of speech were allowed in Singapore, it would likely also degenerate into a "dictatorship of the mobs", in which Peter lobbies or protests to steal what is Paul's. Personally, my only reason for participating in mass protests is war. But since Singapore does not participate in attacking other countries, there is no need for antiwar protests anyway. So again this is acceptable to me in my life design plan.
Similarly, because you don't declare tax on interest earned from bank deposits, the government has no way of finding out how much you have and in which bank.
I like my privacy. Indeed, here you don't have to worry about keeping detailed bank records and having to calculate gains on owning different currencies, a virtually impossible job. The last time I did my taxes here it took me just three minutes.
Contrary to the rationalizations of procrastinators, it is much easier to move to a new country when you are still young, have no family and do not have much wealth. Once you are settled in a job in your home country, your unrealized capital gains keep accumulating. After a certain threshold, this might make your exit tax requirement so prohibitive that… ironically… for tax reasons, you do not go even if you have every intention and reason to leave your country.
The life of an international man requires him to stop seeing the world in black and white.
He must not pigeonhole countries, but design his life in order to secure his wealth and freedom as much as he can. That can often mean giving up residence in what is generally perceived as a relatively "free" country.
You have to design your own freedom.
Shop where goods are cheap and there is no sales tax… Be a tax resident where you have minimal tax requirements… Spend time in places where the cost of living is low and the quality of life is high… Seek a jurisdiction where real freedom and anonymity exist… Keep most of your money in countries different from where you live… Own passports for countries where you don't live.
And best of all, with a bit of effort, this can all be done perfectly legally and will let you stay one step ahead of your government.


Boulder's move to limit the spread of McMansions is speeding up, as the City Council scheduled an emergency vote on a measure that will either temporarily outlaw large homes or make them more expensive to build.
At a Monday-morning agenda meeting, council members added a public hearing to the next day's meeting, at the request of councilwoman Lisa Morzel. Up for consideration is an ordinance that would temporarily stop the city's processing of permits for homes larger than 3,500 square feet on lots 10,000 square feet or larger.
Those particular numbers were chosen because of a 2016 report from the Daily Camera that highlighted the proliferation of big, new houses in Boulder's many low-density neighborhoods: Two-thirds of all houses built since 2010 were 3,500 square feet or more, the Camera found.
Council has expressed a concern that bigger houses are replacing smaller, more affordable homes. In a study session last month, members discussed ways to promote the building of humbler abodes, such as by allowing the subdivision of lots and waiving of some density requirements in exchange for affordability. Staff was directed to explore options and gather data before bringing recommendations back to council.


text:
<?php

// no direct access
defined('_JEXEC') or die ;

jimport('joomla.application.component.model');

JTable::addIncludePath(JPATH_COMPONENT.DS.'tables');

class K2ModelItems extends K2Model
{

	function getData()
	{

		$mainframe = JFactory::getApplication();
		$params = JComponentHelper::getParams('com_k2');
		$option = JRequest::getCmd('option');
		$view = JRequest::getCmd('view');
		$db = JFactory::getDBO();
		$limit = $mainframe->getUserStateFromRequest('global.list.limit', 'limit', $mainframe->getCfg('list_limit'), 'int');
		$limitstart = $mainframe->getUserStateFromRequest($option.$view.'.limitstart', 'limitstart', 0, 'int');
		$filter_order = $mainframe->getUserStateFromRequest($option.$view.'filter_order', 'filter_order', 'i.id', 'cmd');
		$filter_order_Dir = $mainframe->getUserStateFromRequest($option.$view.'filter_order_Dir', 'filter_order_Dir', 'DESC', 'word');
		$filter_trash = $mainframe->getUserStateFromRequest($option.$view.'filter_trash', 'filter_trash', 0, 'int');
		$filter_featured = $mainframe->getUserStateFromRequest($option.$view.'filter_featured', 'filter_featured', -1, 'int');
		$filter_category = $mainframe->getUserStateFromRequest($option.$view.'filter_category', 'filter_category', 0, 'int');
		$filter_author = $mainframe->getUserStateFromRequest($option.$view.'filter_author', 'filter_author', 0, 'int');
		$filter_state = $mainframe->getUserStateFromRequest($option.$view.'filter_state', 'filter_state', -1, 'int');
		$search = $mainframe->getUserStateFromRequest($option.$view.'search', 'search', '', 'string');
		$search = JString::strtolower($search);
		$tag = $mainframe->getUserStateFromRequest($option.$view.'tag', 'tag', 0, 'int');
		$language = $mainframe->getUserStateFromRequest($option.$view.'language', 'language', '', 'string');

		$query = "SELECT i.*, g.name AS groupname, c.name AS category, v.name AS author, w.name as moderator, u.name AS editor FROM #__k2_items as i";

		$query .= " LEFT JOIN #__k2_categories AS c ON c.id = i.catid"." LEFT JOIN #__groups AS g ON g.id = i.access"." LEFT JOIN #__users AS u ON u.id = i.checked_out"." LEFT JOIN #__users AS v ON v.id = i.created_by"." LEFT JOIN #__users AS w ON w.id = i.modified_by";

		if ($params->get('showTagFilter') && $tag)
		{
			$query .= " LEFT JOIN #__k2_tags_xref AS tags_xref ON tags_xref.itemID = i.id";
		}

		$query .= " WHERE i.trash={$filter_trash}";

		if ($search)
		{
			$escaped = K2_JVERSION == '15' ? $db->getEscaped($search, true) : $db->escape($search, true);
			$quoted = $db->Quote('%'.$escaped.'%', false);

			if ($params->get('adminSearch') == 'full')
			{
				$query .= " AND ( LOWER(i.title) LIKE ".$quoted." OR LOWER(i.introtext) LIKE ".$quoted." OR LOWER(i.`fulltext`) LIKE ".$quoted." OR LOWER(i.extra_fields_search) LIKE ".$quoted." OR LOWER(i.image_caption) LIKE ".$quoted." OR LOWER(i.image_credits) LIKE ".$quoted." OR LOWER(i.video_caption) LIKE ".$quoted." OR LOWER(i.video_credits) LIKE ".$quoted." OR LOWER(i.metadesc) LIKE ".$quoted." OR LOWER(i.metakey) LIKE ".$quoted.") ";
			}
			else
			{
				$query .= " AND LOWER(i.title) LIKE ".$quoted;
			}
		}

		if ($filter_state > -1)
		{
			$query .= " AND i.published={$filter_state}";
		}

		if ($filter_featured > -1)
		{
			$query .= " AND i.featured={$filter_featured}";
		}

		if ($filter_category > 0)
		{
			if ($params->get('showChildCatItems'))
			{
				K2Model::addIncludePath(JPATH_SITE.DS.'components'.DS.'com_k2'.DS.'models');
				$itemListModel = K2Model::getInstance('Itemlist', 'K2Model');
				$categories = $itemListModel->getCategoryTree($filter_category);
				$sql = @implode(',', $categories);
				$query .= " AND i.catid IN ({$sql})";
			}
			else
			{
				$query .= " AND i.catid={$filter_category}";
			}

		}

		if ($filter_author > 0)
		{
			$query .= " AND i.created_by={$filter_author}";
		}

		if ($params->get('showTagFilter') && $tag)
		{
			$query .= " AND tags_xref.tagID = {$tag}";
		}

		if ($language)
		{
			$query .= " AND (i.language = ".$db->Quote($language)." OR i.language = '*')";
		}

		if ($filter_order == 'i.ordering')
		{
			$query .= " ORDER BY i.catid, i.ordering {$filter_order_Dir}";
		}
		else
		{
			$query .= " ORDER BY {$filter_order} {$filter_order_Dir} ";
		}

		if (K2_JVERSION != '15')
		{
			$query = JString::str_ireplace('#__groups', '#__viewlevels', $query);
			$query = JString::str_ireplace('g.name', 'g.title', $query);
		}
		$dispatcher = JDispatcher::getInstance();
		JPluginHelper::importPlugin('k2');
		$dispatcher->trigger('onK2BeforeSetQuery', array(&$query));
		$db->setQuery($query, $limitstart, $limit);
		$rows = $db->loadObjectList();
		return $rows;

	}

	function getTotal()
	{

		$mainframe = JFactory::getApplication();
		$params = JComponentHelper::getParams('com_k2');
		$option = JRequest::getCmd('option');
		$view = JRequest::getCmd('view');
		$db = JFactory::getDBO();
		$filter_trash = $mainframe->getUserStateFromRequest($option.$view.'filter_trash', 'filter_trash', 0, 'int');
		$filter_featured = $mainframe->getUserStateFromRequest($option.$view.'filter_featured', 'filter_featured', -1, 'int');
		$filter_category = $mainframe->getUserStateFromRequest($option.$view.'filter_category', 'filter_category', 0, 'int');
		$filter_author = $mainframe->getUserStateFromRequest($option.$view.'filter_author', 'filter_author', 0, 'int');
		$filter_state = $mainframe->getUserStateFromRequest($option.$view.'filter_state', 'filter_state', -1, 'int');
		$search = $mainframe->getUserStateFromRequest($option.$view.'search', 'search', '', 'string');
		$search = JString::strtolower($search);
		$tag = $mainframe->getUserStateFromRequest($option.$view.'tag', 'tag', 0, 'int');
		$language = $mainframe->getUserStateFromRequest($option.$view.'language', 'language', '', 'string');

		$query = "SELECT COUNT(*) FROM #__k2_items AS i ";

		if ($params->get('showTagFilter') && $tag)
		{
			$query .= " LEFT JOIN #__k2_tags_xref AS tags_xref ON tags_xref.itemID = i.id";
		}

		$query .= " WHERE trash={$filter_trash} ";

		if ($search)
		{
			$escaped = K2_JVERSION == '15' ? $db->getEscaped($search, true) : $db->escape($search, true);
			$quoted = $db->Quote('%'.$escaped.'%', false);

			if ($params->get('adminSearch') == 'full')
			{
				$query .= " AND ( LOWER(i.title) LIKE ".$quoted." OR LOWER(i.introtext) LIKE ".$quoted." OR LOWER(i.`fulltext`) LIKE ".$quoted." OR LOWER(i.extra_fields_search) LIKE ".$quoted." OR LOWER(i.image_caption) LIKE ".$quoted." OR LOWER(i.image_credits) LIKE ".$quoted." OR LOWER(i.video_caption) LIKE ".$quoted." OR LOWER(i.video_credits) LIKE ".$quoted." OR LOWER(i.metadesc) LIKE ".$quoted." OR LOWER(i.metakey) LIKE ".$quoted.") ";
			}
			else
			{
				$query .= " AND LOWER(i.title) LIKE ".$quoted;
			}
		}

		if ($filter_state > -1)
		{
			$query .= " AND published={$filter_state}";
		}

		if ($filter_featured > -1)
		{
			$query .= " AND featured={$filter_featured}";
		}

		if ($filter_category > 0)
		{
			if ($params->get('showChildCatItems'))
			{
				K2Model::addIncludePath(JPATH_SITE.DS.'components'.DS.'com_k2'.DS.'models');
				$itemListModel = K2Model::getInstance('Itemlist', 'K2Model');
				$categories = $itemListModel->getCategoryTree($filter_category);
				$sql = @implode(',', $categories);
				$query .= " AND catid IN ({$sql})";
			}
			else
			{
				$query .= " AND catid={$filter_category}";
			}

		}

		if ($filter_author > 0)
		{
			$query .= " AND created_by={$filter_author}";
		}

		if ($params->get('showTagFilter') && $tag)
		{
			$query .= " AND tags_xref.tagID = {$tag}";
		}

		if ($language)
		{
			$query .= " AND (language = ".$db->Quote($language)." OR language = '*')";
		}
		$dispatcher = JDispatcher::getInstance();
		JPluginHelper::importPlugin('k2');
		$dispatcher->trigger('onK2BeforeSetQuery', array(&$query));
		$db->setQuery($query);
		$result = $db->loadResult();
		return $result;

	}

	function publish()
	{

		$mainframe = JFactory::getApplication();
		$cid = JRequest::getVar('cid');
		foreach ($cid as $id)
		{
			$row = JTable::getInstance('K2Item', 'Table');
			$row->load($id);
			$row->published = 1;
			$row->store();
		}
		JPluginHelper::importPlugin('finder');
		$dispatcher = JDispatcher::getInstance();
		$dispatcher->trigger('onFinderChangeState', array(
			'com_k2.item',
			$cid,
			1
		));
		$cache = JFactory::getCache('com_k2');
		$cache->clean();
		$mainframe->redirect('index.php?option=com_k2&view=items');
	}

	function unpublish()
	{

		$mainframe = JFactory::getApplication();
		$cid = JRequest::getVar('cid');
		foreach ($cid as $id)
		{
			$row = JTable::getInstance('K2Item', 'Table');
			$row->load($id);
			$row->published = 0;
			$row->store();
		}
		JPluginHelper::importPlugin('finder');
		$dispatcher = JDispatcher::getInstance();
		$dispatcher->trigger('onFinderChangeState', array(
			'com_k2.item',
			$cid,
			0
		));
		$cache = JFactory::getCache('com_k2');
		$cache->clean();
		$mainframe->redirect('index.php?option=com_k2&view=items');
	}

	function saveorder()
	{

		$mainframe = JFactory::getApplication();
		$db = JFactory::getDBO();
		$cid = JRequest::getVar('cid', array(0), 'post', 'array');
		$total = count($cid);
		$order = JRequest::getVar('order', array(0), 'post', 'array');
		JArrayHelper::toInteger($order, array(0));
		$groupings = array();
		for ($i = 0; $i < $total; $i++)
		{
			$row = JTable::getInstance('K2Item', 'Table');
			$row->load((int)$cid[$i]);
			$groupings[] = $row->catid;
			if ($row->ordering != $order[$i])
			{
				$row->ordering = $order[$i];
				if (!$row->store())
				{
					JError::raiseError(500, $db->getErrorMsg());
				}
			}
		}
		$params = JComponentHelper::getParams('com_k2');
		if (!$params->get('disableCompactOrdering'))
		{
			$groupings = array_unique($groupings);
			foreach ($groupings as $group)
			{
				$row = JTable::getInstance('K2Item', 'Table');
				$row->reorder('catid = '.(int)$group.' AND trash=0');
			}
		}
		$cache = JFactory::getCache('com_k2');
		$cache->clean();
		return true;
	}

	function orderup()
	{

		$mainframe = JFactory::getApplication();
		$cid = JRequest::getVar('cid');
		$row = JTable::getInstance('K2Item', 'Table');
		$row->load($cid[0]);
		$row->move(-1, 'catid = '.(int)$row->catid.' AND trash=0');
		$params = JComponentHelper::getParams('com_k2');
		if (!$params->get('disableCompactOrdering'))
			$row->reorder('catid = '.(int)$row->catid.' AND trash=0');
		$cache = JFactory::getCache('com_k2');
		$cache->clean();
		$msg = JText::_('K2_NEW_ORDERING_SAVED');
		$mainframe->enqueueMessage($msg);
		$mainframe->redirect('index.php?option=com_k2&view=items');
	}

	function orderdown()
	{

		$mainframe = JFactory::getApplication();
		$cid = JRequest::getVar('cid');
		$row = JTable::getInstance('K2Item', 'Table');
		$row->load($cid[0]);
		$row->move(1, 'catid = '.(int)$row->catid.' AND trash=0');
		$params = JComponentHelper::getParams('com_k2');
		if (!$params->get('disableCompactOrdering'))
			$row->reorder('catid = '.(int)$row->catid.' AND trash=0');
		$cache = JFactory::getCache('com_k2');
		$cache->clean();
		$msg = JText::_('K2_NEW_ORDERING_SAVED');
		$mainframe->enqueueMessage($msg);
		$mainframe->redirect('index.php?option=com_k2&view=items');
	}

	function savefeaturedorder()
	{

		$mainframe = JFactory::getApplication();
		$db = JFactory::getDBO();
		$cid = JRequest::getVar('cid', array(0), 'post', 'array');
		$total = count($cid);
		$order = JRequest::getVar('order', array(0), 'post', 'array');
		JArrayHelper::toInteger($order, array(0));
		$groupings = array();
		for ($i = 0; $i < $total; $i++)
		{
			$row = JTable::getInstance('K2Item', 'Table');
			$row->load((int)$cid[$i]);
			$groupings[] = $row->catid;
			if ($row->featured_ordering != $order[$i])
			{
				$row->featured_ordering = $order[$i];
				if (!$row->store())
				{
					JError::raiseError(500, $db->getErrorMsg());
				}
			}
		}
		$params = JComponentHelper::getParams('com_k2');
		if (!$params->get('disableCompactOrdering'))
		{
			$groupings = array_unique($groupings);
			foreach ($groupings as $group)
			{
				$row = JTable::getInstance('K2Item', 'Table');
				$row->reorder('featured = 1 AND trash=0', 'featured_ordering');
			}
		}
		$cache = JFactory::getCache('com_k2');
		$cache->clean();
		return true;
	}

	function featuredorderup()
	{

		$mainframe = JFactory::getApplication();
		$cid = JRequest::getVar('cid');
		$row = JTable::getInstance('K2Item', 'Table');
		$row->load($cid[0]);
		$row->move(-1, 'featured=1 AND trash=0', 'featured_ordering');
		$params = JComponentHelper::getParams('com_k2');
		if (!$params->get('disableCompactOrdering'))
			$row->reorder('featured=1 AND trash=0', 'featured_ordering');
		$cache = JFactory::getCache('com_k2');
		$cache->clean();
		$msg = JText::_('K2_NEW_ORDERING_SAVED');
		$mainframe->enqueueMessage($msg);
		$mainframe->redirect('index.php?option=com_k2&view=items');
	}

	function featuredorderdown()
	{

		$mainframe = JFactory::getApplication();
		$cid = JRequest::getVar('cid');
		$row = JTable::getInstance('K2Item', 'Table');
		$row->load($cid[0]);
		$row->move(1, 'featured=1 AND trash=0', 'featured_ordering');
		$params = JComponentHelper::getParams('com_k2');
		if (!$params->get('disableCompactOrdering'))
			$row->reorder('featured=1 AND trash=0', 'featured_ordering');
		$cache = JFactory::getCache('com_k2');
		$cache->clean();
		$msg = JText::_('K2_NEW_ORDERING_SAVED');
		$mainframe->enqueueMessage($msg);
		$mainframe->redirect('index.php?option=com_k2&view=items');
	}

	function accessregistered()
	{

		$mainframe = JFactory::getApplication();
		$db = JFactory::getDBO();
		$row = JTable::getInstance('K2Item', 'Table');
		$cid = JRequest::getVar('cid');
		$row->load($cid[0]);
		$row->access = 1;
		if (!$row->check())
		{
			return $row->getError();
		}
		if (!$row->store())
		{
			return $row->getError();
		}
		$cache = JFactory::getCache('com_k2');
		$cache->clean();
		$msg = JText::_('K2_NEW_ACCESS_SETTING_SAVED');
		$mainframe->enqueueMessage($msg);
		$mainframe->redirect('index.php?option=com_k2&view=items');
	}

	function accessspecial()
	{

		$mainframe = JFactory::getApplication();
		$db = JFactory::getDBO();
		$row = JTable::getInstance('K2Item', 'Table');
		$cid = JRequest::getVar('cid');
		$row->load($cid[0]);
		$row->access = 2;
		if (!$row->check())
		{
			return $row->getError();
		}
		if (!$row->store())
		{
			return $row->getError();
		}
		$cache = JFactory::getCache('com_k2');
		$cache->clean();
		$msg = JText::_('K2_NEW_ACCESS_SETTING_SAVED');
		$mainframe->enqueueMessage($msg);
		$mainframe->redirect('index.php?option=com_k2&view=items');
	}

	function accesspublic()
	{

		$mainframe = JFactory::getApplication();
		$db = JFactory::getDBO();
		$row = JTable::getInstance('K2Item', 'Table');
		$cid = JRequest::getVar('cid');
		$row->load($cid[0]);
		$row->access = 0;
		if (!$row->check())
		{
			return $row->getError();
		}
		if (!$row->store())
		{
			return $row->getError();
		}
		$cache = JFactory::getCache('com_k2');
		$cache->clean();
		$msg = JText::_('K2_NEW_ACCESS_SETTING_SAVED');
		$mainframe->enqueueMessage($msg);
		$mainframe->redirect('index.php?option=com_k2&view=items');
	}

	function copy()
	{

		$mainframe = JFactory::getApplication();
		jimport('joomla.filesystem.file');
		jimport('joomla.filesystem.folder');
		$params = JComponentHelper::getParams('com_k2');
		$itemModel = K2Model::getInstance('Item', 'K2Model');
		$db = JFactory::getDBO();
		$cid = JRequest::getVar('cid');
		JArrayHelper::toInteger($cid);
		$row = JTable::getInstance('K2Item', 'Table');

		$nullDate = $db->getNullDate();

		foreach ($cid as $id)
		{

			//Load source item
			$item = JTable::getInstance('K2Item', 'Table');
			$item->load($id);
			$item->id = (int)$item->id;

			//Source images
			$sourceImage = JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'src'.DS.md5("Image".$item->id).'.jpg';
			$sourceImageXS = JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$item->id).'_XS.jpg';
			$sourceImageS = JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$item->id).'_S.jpg';
			$sourceImageM = JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$item->id).'_M.jpg';
			$sourceImageL = JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$item->id).'_L.jpg';
			$sourceImageXL = JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$item->id).'_XL.jpg';
			$sourceImageGeneric = JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$item->id).'_Generic.jpg';

			//Source gallery
			$sourceGallery = JPATH_ROOT.DS.'media'.DS.'k2'.DS.'galleries'.DS.$item->id;
			$sourceGalleryTag = $item->gallery;

			//Source video
			preg_match_all("#^{(.*?)}(.*?){#", $item->video, $matches, PREG_PATTERN_ORDER);
			$videotype = $matches[1][0];
			$videofile = $matches[2][0];

			if ($videotype == 'flv' || $videotype == 'swf' || $videotype == 'wmv' || $videotype == 'mov' || $videotype == 'mp4' || $videotype == '3gp' || $videotype == 'divx')
			{
				if (JFile::exists(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'videos'.DS.$videofile.'.'.$videotype))
				{
					$sourceVideo = $videofile.'.'.$videotype;
					//$row->video='{'.$videotype.'}'.$row->id.'{/'.$videotype.'}';
				}
			}

			//Source tags
			$query = "SELECT * FROM #__k2_tags_xref WHERE itemID={$item->id}";
			$db->setQuery($query);
			$sourceTags = $db->loadObjectList();

			//Source Attachments
			$sourceAttachments = $itemModel->getAttachments($item->id);

			//Save target item
			$row = JTable::getInstance('K2Item', 'Table');
			$row = $item;
			$row->id = NULL;
			$row->title = JText::_('K2_COPY_OF').' '.$item->title;
			$row->hits = 0;
			$row->published = 0;
			$datenow = JFactory::getDate();
			$row->created = K2_JVERSION == '15' ? $datenow->toMySQL() : $datenow->toSql();
			$row->modified = $nullDate;
			$row->store();

			//Target images
			if (JFile::exists($sourceImage))
				JFile::copy($sourceImage, JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'src'.DS.md5("Image".$row->id).'.jpg');
			if (JFile::exists($sourceImageXS))
				JFile::copy($sourceImageXS, JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$row->id).'_XS.jpg');
			if (JFile::exists($sourceImageS))
				JFile::copy($sourceImageS, JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$row->id).'_S.jpg');
			if (JFile::exists($sourceImageM))
				JFile::copy($sourceImageM, JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$row->id).'_M.jpg');
			if (JFile::exists($sourceImageL))
				JFile::copy($sourceImageL, JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$row->id).'_L.jpg');
			if (JFile::exists($sourceImageXL))
				JFile::copy($sourceImageXL, JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$row->id).'_XL.jpg');
			if (JFile::exists($sourceImageGeneric))
				JFile::copy($sourceImageGeneric, JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$row->id).'_Generic.jpg');

			//Target gallery
			if ($sourceGalleryTag)
			{
				if (JString::strpos($sourceGalleryTag, 'http://'))
				{
					$row->gallery = $sourceGalleryTag;
				}
				else
				{
					$row->gallery = '{gallery}'.$row->id.'{/gallery}';
					if (JFolder::exists($sourceGallery))
					{
						JFolder::copy($sourceGallery, JPATH_ROOT.DS.'media'.DS.'k2'.DS.'galleries'.DS.$row->id);
					}
				}
			}

			//Target video
			if (isset($sourceVideo) && JFile::exists(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'videos'.DS.$sourceVideo))
			{
				JFile::copy(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'videos'.DS.$sourceVideo, JPATH_ROOT.DS.'media'.DS.'k2'.DS.'videos'.DS.$row->id.'.'.$videotype);
				$row->video = '{'.$videotype.'}'.$row->id.'{/'.$videotype.'}';
			}

			//Target attachments
			$path = $params->get('attachmentsFolder', NULL);
			if (is_null($path))
				$savepath = JPATH_ROOT.DS.'media'.DS.'k2'.DS.'attachments';
			else
				$savepath = $path;

			foreach ($sourceAttachments as $attachment)
			{
				if (JFile::exists($savepath.DS.$attachment->filename))
				{
					JFile::copy($savepath.DS.$attachment->filename, $savepath.DS.$row->id.'_'.$attachment->filename);
					$attachmentRow = JTable::getInstance('K2Attachment', 'Table');
					$attachmentRow->itemID = $row->id;
					$attachmentRow->title = $attachment->title;
					$attachmentRow->titleAttribute = $attachment->titleAttribute;
					$attachmentRow->filename = $row->id.'_'.$attachment->filename;
					$attachmentRow->hits = 0;
					$attachmentRow->store();
				}
			}

			//Target tags
			foreach ($sourceTags as $tag)
			{
				$query = "INSERT INTO #__k2_tags_xref (`id`, `tagID`, `itemID`) VALUES (NULL, {intval($tag->tagID)}, {intval($row->id)})";
				$db->setQuery($query);
				$db->query();
			}

			$row->store();
		}
		$mainframe->enqueueMessage(JText::_('K2_COPY_COMPLETED'));
		$mainframe->redirect('index.php?option=com_k2&view=items');
	}

	function featured()
	{

		$mainframe = JFactory::getApplication();
		$db = JFactory::getDBO();
		$cid = JRequest::getVar('cid');
		foreach ($cid as $id)
		{
			$row = JTable::getInstance('K2Item', 'Table');
			$row->load($id);
			if ($row->featured == 1)
				$row->featured = 0;
			else
			{
				$row->featured = 1;
				$row->featured_ordering = 1;
			}
			$row->store();
		}
		$cache = JFactory::getCache('com_k2');
		$cache->clean();
		$mainframe->enqueueMessage(JText::_('K2_ITEMS_CHANGED'));
		$mainframe->redirect('index.php?option=com_k2&view=items');
	}

	function trash()
	{

		$mainframe = JFactory::getApplication();
		$db = JFactory::getDBO();
		$cid = JRequest::getVar('cid');
		JArrayHelper::toInteger($cid);
		foreach ($cid as $id)
		{
			$row = JTable::getInstance('K2Item', 'Table');
			$row->load($id);
			$row->trash = 1;
			$row->store();
		}
		$cache = JFactory::getCache('com_k2');
		$cache->clean();
		$mainframe->enqueueMessage(JText::_('K2_ITEMS_MOVED_TO_TRASH'));
		$mainframe->redirect('index.php?option=com_k2&view=items');

	}

	function restore()
	{

		$mainframe = JFactory::getApplication();
		$db = JFactory::getDBO();
		$cid = JRequest::getVar('cid');
		$warning = false;
		foreach ($cid as $id)
		{
			$row = JTable::getInstance('K2Item', 'Table');
			$row->load($id);
			$query = "SELECT COUNT(*) FROM #__k2_categories WHERE id=".(int)$row->catid." AND trash = 0";
			$db->setQuery($query);
			$result = $db->loadResult();
			if ($result)
			{
				$row->trash = 0;
				$row->store();
			}
			else
			{
				$warning = true;
			}

		}
		$cache = JFactory::getCache('com_k2');
		$cache->clean();
		if ($warning)
			$mainframe->enqueueMessage(JText::_('K2_SOME_OF_THE_ITEMS_HAVE_NOT_BEEN_RESTORED_BECAUSE_THEY_BELONG_TO_A_CATEGORY_WHICH_IS_IN_TRASH'), 'notice');
		$mainframe->enqueueMessage(JText::_('K2_ITEMS_RESTORED'));
		$mainframe->redirect('index.php?option=com_k2&view=items');

	}

	function remove()
	{
		jimport('joomla.filesystem.file');
		jimport('joomla.filesystem.folder');
		$mainframe = JFactory::getApplication();
		$params = JComponentHelper::getParams('com_k2');
		$itemModel = K2Model::getInstance('Item', 'K2Model');
		$db = JFactory::getDBO();
		$cid = JRequest::getVar('cid');
		JPluginHelper::importPlugin('finder');
		$dispatcher = JDispatcher::getInstance();
		foreach ($cid as $id)
		{
			$row = JTable::getInstance('K2Item', 'Table');
			$row->load($id);
			$row->id = (int)$row->id;
			//Delete images
			if (JFile::exists(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'src'.DS.md5("Image".$row->id).'.jpg'))
			{
				JFile::delete(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'src'.DS.md5("Image".$row->id).'.jpg');
			}
			if (JFile::exists(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$row->id).'_XS.jpg'))
			{
				JFile::delete(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$row->id).'_XS.jpg');
			}
			if (JFile::exists(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$row->id).'_S.jpg'))
			{
				JFile::delete(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$row->id).'_S.jpg');
			}
			if (JFile::exists(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$row->id).'_M.jpg'))
			{
				JFile::delete(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$row->id).'_M.jpg');
			}
			if (JFile::exists(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$row->id).'_L.jpg'))
			{
				JFile::delete(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$row->id).'_L.jpg');
			}
			if (JFile::exists(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$row->id).'_XL.jpg'))
			{
				JFile::delete(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$row->id).'_XL.jpg');
			}
			if (JFile::exists(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$row->id).'_Generic.jpg'))
			{
				JFile::delete(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'items'.DS.'cache'.DS.md5("Image".$row->id).'_Generic.jpg');
			}

			//Delete gallery
			if (JFolder::exists(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'galleries'.DS.$row->id))
				JFolder::delete(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'galleries'.DS.$row->id);

			//Delete video
			preg_match_all("#^{(.*?)}(.*?){#", $row->video, $matches, PREG_PATTERN_ORDER);
			$videotype = $matches[1][0];
			$videofile = $matches[2][0];

			$videoExtensions = array(
				'flv',
				'mp4',
				'ogv',
				'webm',
				'f4v',
				'm4v',
				'3gp',
				'3g2',
				'mov',
				'mpeg',
				'mpg',
				'avi',
				'wmv',
				'divx',
				'swf'
			);
			$audioExtensions = array(
				'mp3',
				'aac',
				'mp4',
				'ogg',
				'wma'
			);

			if (in_array($videotype, $videoExtensions) || in_array($videotype, $audioExtensions))
			{

				if (JFile::exists(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'videos'.DS.$videofile.'.'.$videotype))
					JFile::delete(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'videos'.DS.$videofile.'.'.$videotype);

				if (JFile::exists(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'audio'.DS.$videofile.'.'.$videotype))
					JFile::delete(JPATH_ROOT.DS.'media'.DS.'k2'.DS.'audio'.DS.$videofile.'.'.$videotype);
			}

			//Delete attachments
			$path = $params->get('attachmentsFolder', NULL);
			if (is_null($path))
				$savepath = JPATH_ROOT.DS.'media'.DS.'k2'.DS.'attachments';
			else
				$savepath = $path;

			$attachments = $itemModel->getAttachments($row->id);

			foreach ($attachments as $attachment)
			{
				if (JFile::exists($savepath.DS.$attachment->filename))
					JFile::delete($savepath.DS.$attachment->filename);
			}

			$query = "DELETE FROM #__k2_attachments WHERE itemID={$row->id}";
			$db->setQuery($query);
			$db->query();

			//Delete tags
			$query = "DELETE FROM #__k2_tags_xref WHERE itemID={$row->id}";
			$db->setQuery($query);
			$db->query();

			//Delete comments
			$query = "DELETE FROM #__k2_comments WHERE itemID={$row->id}";
			$db->setQuery($query);
			$db->query();

			$row->delete($id);

			$dispatcher->trigger('onFinderAfterDelete', array(
				'com_k2.item',
				$row
			));
		}
		$cache = JFactory::getCache('com_k2');
		$cache->clean();
		$mainframe->enqueueMessage(JText::_('K2_DELETE_COMPLETED'));
		$mainframe->redirect('index.php?option=com_k2&view=items');
	}

	function import()
	{

		$mainframe = JFactory::getApplication();
		jimport('joomla.filesystem.file');
		$db = JFactory::getDBO();
		$query = "SELECT * FROM #__sections";
		$db->setQuery($query);
		$sections = $db->loadObjectList();

		$query = "SELECT COUNT(*) FROM #__k2_items";
		$db->setQuery($query);
		$result = $db->loadResult();
		if ($result)
			$preserveItemIDs = false;
		else
			$preserveItemIDs = true;

		$xml = new JSimpleXML;
		$xml->loadFile(JPATH_COMPONENT.DS.'models'.DS.'category.xml');
		$categoryParams = class_exists('JParameter') ? new JParameter('') : new JRegistry('');

		foreach ($xml->document->params as $paramGroup)
		{
			foreach ($paramGroup->param as $param)
			{
				if ($param->attributes('type') != 'spacer' && $param->attributes('name'))
				{
					$categoryParams->set($param->attributes('name'), $param->attributes('default'));
				}
			}
		}
		$categoryParams = $categoryParams->toString();

		$xml = new JSimpleXML;
		$xml->loadFile(JPATH_COMPONENT.DS.'models'.DS.'item.xml');
		$itemParams = class_exists('JParameter') ? new JParameter('') : new JRegistry('');

		foreach ($xml->document->params as $paramGroup)
		{
			foreach ($paramGroup->param as $param)
			{
				if ($param->attributes('type') != 'spacer' && $param->attributes('name'))
				{
					$itemParams->set($param->attributes('name'), $param->attributes('default'));
				}
			}
		}
		$itemParams = $itemParams->toString();

		$query = "SELECT id, name FROM #__k2_tags";
		$db->setQuery($query);
		$tags = $db->loadObjectList();

		if (is_null($tags))
			$tags = array();

		foreach ($sections as $section)
		{
			$K2Category = JTable::getInstance('K2Category', 'Table');
			$K2Category->name = $section->title;
			$K2Category->alias = $section->title;
			$K2Category->description = $section->description;
			$K2Category->parent = 0;
			$K2Category->published = $section->published;
			$K2Category->access = $section->access;
			$K2Category->ordering = $section->ordering;
			$K2Category->image = $section->image;
			$K2Category->trash = 0;
			$K2Category->params = $categoryParams;
			$K2Category->check();
			$K2Category->store();
			if (JFile::exists(JPATH_SITE.DS.'images'.DS.'stories'.DS.$section->image))
			{
				JFile::copy(JPATH_SITE.DS.'images'.DS.'stories'.DS.$section->image, JPATH_SITE.DS.'media'.DS.'k2'.DS.'categories'.DS.$K2Category->image);
			}
			$query = "SELECT * FROM #__categories WHERE section = ".(int)$section->id;
			$db->setQuery($query);
			$categories = $db->loadObjectList();

			foreach ($categories as $category)
			{
				$K2Subcategory = JTable::getInstance('K2Category', 'Table');
				$K2Subcategory->name = $category->title;
				$K2Subcategory->alias = $category->title;
				$K2Subcategory->description = $category->description;
				$K2Subcategory->parent = $K2Category->id;
				$K2Subcategory->published = $category->published;
				$K2Subcategory->access = $category->access;
				$K2Subcategory->ordering = $category->ordering;
				$K2Subcategory->image = $category->image;
				$K2Subcategory->trash = 0;
				$K2Subcategory->params = $categoryParams;
				$K2Subcategory->check();
				$K2Subcategory->store();
				if (JFile::exists(JPATH_SITE.DS.'images'.DS.'stories'.DS.$category->image))
				{
					JFile::copy(JPATH_SITE.DS.'images'.DS.'stories'.DS.$category->image, JPATH_SITE.DS.'media'.DS.'k2'.DS.'categories'.DS.$K2Subcategory->image);
				}

				$query = "SELECT article.*, xref.content_id
				FROM #__content AS article
				LEFT JOIN #__content_frontpage AS xref ON article.id = xref.content_id
				WHERE catid = ".(int)$category->id;
				$db->setQuery($query);
				$items = $db->loadObjectList();

				foreach ($items as $item)
				{

					$K2Item = JTable::getInstance('K2Item', 'Table');
					$K2Item->title = $item->title;
					$K2Item->alias = $item->title;
					$K2Item->catid = $K2Subcategory->id;
					if ($item->state < 0)
					{
						$K2Item->trash = 1;
					}
					else
					{
						$K2Item->trash = 0;
						$K2Item->published = $item->state;
					}
					$K2Item->featured = ($item->content_id) ? 1 : 0;
					$K2Item->introtext = $item->introtext;
					$K2Item->fulltext = $item->fulltext;
					$K2Item->created = $item->created;
					$K2Item->created_by = $item->created_by;
					$K2Item->created_by_alias = $item->created_by_alias;
					$K2Item->modified = $item->modified;
					$K2Item->modified_by = $item->modified_by;
					$K2Item->publish_up = $item->publish_up;
					$K2Item->publish_down = $item->publish_down;
					$K2Item->access = $item->access;
					$K2Item->ordering = $item->ordering;
					$K2Item->hits = $item->hits;
					$K2Item->metadesc = $item->metadesc;
					$K2Item->metadata = $item->metadata;
					$K2Item->metakey = $item->metakey;
					$K2Item->params = $itemParams;
					$K2Item->check();
					if ($preserveItemIDs)
					{
						$K2Item->id = $item->id;
						$db->insertObject('#__k2_items', $K2Item);
					}
					else
					{
						$K2Item->store();
					}

					if (!empty($item->metakey))
					{
						$itemTags = explode(',', $item->metakey);
						foreach ($itemTags as $itemTag)
						{
							$itemTag = JString::trim($itemTag);
							if (in_array($itemTag, JArrayHelper::getColumn($tags, 'name')))
							{

								$query = "SELECT id FROM #__k2_tags WHERE name=".$db->Quote($itemTag);
								$db->setQuery($query);
								$id = $db->loadResult();
								$query = "INSERT INTO #__k2_tags_xref (`id`, `tagID`, `itemID`) VALUES (NULL, {$id}, {$K2Item->id})";
								$db->setQuery($query);
								$db->query();
							}
							else
							{
								$K2Tag = JTable::getInstance('K2Tag', 'Table');
								$K2Tag->name = $itemTag;
								$K2Tag->published = 1;
								$K2Tag->store();
								$tags[] = $K2Tag;
								$query = "INSERT INTO #__k2_tags_xref (`id`, `tagID`, `itemID`) VALUES (NULL, {$K2Tag->id}, {$K2Item->id})";
								$db->setQuery($query);
								$db->query();
							}
						}
					}
				}

			}

		}

		// Handle uncategorized articles
		$query = "SELECT * FROM #__content WHERE sectionid = 0";
		$db->setQuery($query);
		$items = $db->loadObjectList();

		if ($items)
		{
			$K2Uncategorised = JTable::getInstance('K2Category', 'Table');
			$K2Uncategorised->name = 'Uncategorized';
			$K2Uncategorised->alias = 'Uncategorized';
			$K2Uncategorised->parent = 0;
			$K2Uncategorised->published = 1;
			$K2Uncategorised->access = 0;
			$K2Uncategorised->ordering = 0;
			$K2Uncategorised->trash = 0;
			$K2Uncategorised->params = $categoryParams;
			$K2Uncategorised->check();
			$K2Uncategorised->store();

			foreach ($items as $item)
			{

				$K2Item = JTable::getInstance('K2Item', 'Table');
				$K2Item->title = $item->title;
				$K2Item->alias = $item->title;
				$K2Item->catid = $K2Uncategorised->id;
				if ($item->state < 0)
				{
					$K2Item->trash = 1;
				}
				else
				{
					$K2Item->trash = 0;
					$K2Item->published = $item->state;
				}
				$K2Item->introtext = $item->introtext;
				$K2Item->fulltext = $item->fulltext;
				$K2Item->created = $item->created;
				$K2Item->created_by = $item->created_by;
				$K2Item->created_by_alias = $item->created_by_alias;
				$K2Item->modified = $item->modified;
				$K2Item->modified_by = $item->modified_by;
				$K2Item->publish_up = $item->publish_up;
				$K2Item->publish_down = $item->publish_down;
				$K2Item->access = $item->access;
				$K2Item->ordering = $item->ordering;
				$K2Item->hits = $item->hits;
				$K2Item->metadesc = $item->metadesc;
				$K2Item->metadata = $item->metadata;
				$K2Item->metakey = $item->metakey;
				$K2Item->params = $itemParams;
				$K2Item->check();
				if ($preserveItemIDs)
				{
					$K2Item->id = $item->id;
					$db->insertObject('#__k2_items', $K2Item);
				}
				else
				{
					$K2Item->store();
				}

				if (!empty($item->metakey))
				{
					$itemTags = explode(',', $item->metakey);
					foreach ($itemTags as $itemTag)
					{
						$itemTag = JString::trim($itemTag);
						if (in_array($itemTag, JArrayHelper::getColumn($tags, 'name')))
						{

							$query = "SELECT id FROM #__k2_tags WHERE name=".$db->Quote($itemTag);
							$db->setQuery($query);
							$id = $db->loadResult();
							$query = "INSERT INTO #__k2_tags_xref (`id`, `tagID`, `itemID`) VALUES (NULL, {$id}, {$K2Item->id})";
							$db->setQuery($query);
							$db->query();
						}
						else
						{
							$K2Tag = JTable::getInstance('K2Tag', 'Table');
							$K2Tag->name = $itemTag;
							$K2Tag->published = 1;
							$K2Tag->store();
							$tags[] = $K2Tag;
							$query = "INSERT INTO #__k2_tags_xref (`id`, `tagID`, `itemID`) VALUES (NULL, {$K2Tag->id}, {$K2Item->id})";
							$db->setQuery($query);
							$db->query();
						}
					}
				}
			}
		}
		$mainframe->enqueueMessage(JText::_('K2_IMPORT_COMPLETED'));
		$mainframe->redirect('index.php?option=com_k2&view=items');
	}

	function importJ16()
	{

		jimport('joomla.filesystem.file');
		jimport('joomla.html.parameter');
		jimport('joomla.utilities.xmlelement');
		$mainframe = JFactory::getApplication();
		$db = JFactory::getDBO();

		$query = "SELECT COUNT(*) FROM #__k2_categories";
		$db->setQuery($query);
		$result = $db->loadResult();
		if ($result)
		{
			$preserveCategoryIDs = false;
		}
		else
		{
			$preserveCategoryIDs = true;
		}

		$query = "SELECT COUNT(*) FROM #__k2_items";
		$db->setQuery($query);
		$result = $db->loadResult();
		if ($result)
		{
			$preserveItemIDs = false;
		}
		else
		{
			$preserveItemIDs = true;
		}
		$xml = new JXMLElement(JFile::read(JPATH_COMPONENT.DS.'models'.DS.'category.xml'));
		$categoryParams = class_exists('JParameter') ? new JParameter('') : new JRegistry('');
		foreach ($xml->params as $paramGroup)
		{
			foreach ($paramGroup->param as $param)
			{
				if ((string)$param->attributes()->type != 'spacer' && (string)$param->attributes()->name)
				{
					$categoryParams->set((string)$param->attributes()->name, (string)$param->attributes()->default);
				}
			}
		}
		$categoryParams = $categoryParams->toString();

		$xml = new JXMLElement(JFile::read(JPATH_COMPONENT.DS.'models'.DS.'item.xml'));
		$itemParams = class_exists('JParameter') ? new JParameter('') : new JRegistry('');
		foreach ($xml->params as $paramGroup)
		{
			foreach ($paramGroup->param as $param)
			{
				if ((string)$param->attributes()->type != 'spacer' && (string)$param->attributes()->name)
				{
					$itemParams->set((string)$param->attributes()->name, (string)$param->attributes()->default);
				}
			}
		}
		$itemParams = $itemParams->toString();

		$query = "SELECT id, name FROM #__k2_tags";
		$db->setQuery($query);
		$tags = $db->loadObjectList();

		if (is_null($tags))
			$tags = array();

		$query = "SELECT * FROM #__categories WHERE extension = 'com_content'";
		$db->setQuery($query);
		$categories = $db->loadObjectList();
		$mapping = array();
		foreach ($categories as $category)
		{
			$category->params = json_decode($category->params);
			$category->image = $category->params->image;
			$K2Category = JTable::getInstance('K2Category', 'Table');
			$K2Category->name = $category->title;
			$K2Category->alias = $category->title;
			$K2Category->description = $category->description;
			$K2Category->parent = $category->parent_id;
			if ($K2Category->parent == 1)
			{
				$K2Category->parent = 0;
			}
			$K2Category->published = $category->published;
			$K2Category->access = $category->access;
			$K2Category->ordering = $K2Category->getNextOrder('parent='.(int)$category->parent_id);
			$K2Category->image = basename($category->image);
			$K2Category->trash = 0;
			$K2Category->language = $category->language;
			$K2Category->params = $categoryParams;
			$K2Category->check();
			if ($preserveCategoryIDs)
			{
				$K2Category->id = $category->id;
				$db->insertObject('#__k2_categories', $K2Category);
			}
			else
			{
				$K2Category->store();
				$mapping[$category->id] = $K2Category->id;

			}

			if ($K2Category->image && JFile::exists(realpath(JPATH_SITE.DS.$category->image)))
			{
				JFile::copy(realpath(JPATH_SITE.DS.$category->image), JPATH_SITE.DS.'media'.DS.'k2'.DS.'categories'.DS.$K2Category->image);
			}
			$query = "SELECT article.*, xref.content_id
				FROM #__content AS article
				LEFT JOIN #__content_frontpage AS xref ON article.id = xref.content_id
				WHERE catid = ".(int)$category->id;
			$db->setQuery($query);
			$items = $db->loadObjectList();

			foreach ($items as $item)
			{

				$K2Item = JTable::getInstance('K2Item', 'Table');
				$K2Item->title = $item->title;
				$K2Item->alias = $item->title;
				$K2Item->catid = $K2Category->id;
				if ($item->state < 0)
				{
					$K2Item->trash = 1;
				}
				else
				{
					$K2Item->trash = 0;
				}
				$K2Item->published = 1;
				if ($item->state == 0)
				{
					$K2Item->published = 0;
				}
				$K2Item->featured = ($item->content_id) ? 1 : 0;
				$K2Item->introtext = $item->introtext;
				$K2Item->fulltext = $item->fulltext;
				$K2Item->created = $item->created;
				$K2Item->created_by = $item->created_by;
				$K2Item->created_by_alias = $item->created_by_alias;
				$K2Item->modified = $item->modified;
				$K2Item->modified_by = $item->modified_by;
				$K2Item->publish_up = $item->publish_up;
				$K2Item->publish_down = $item->publish_down;
				$K2Item->access = $item->access;
				$K2Item->ordering = $item->ordering;
				$K2Item->hits = $item->hits;
				$K2Item->metadesc = $item->metadesc;
				$K2Item->metadata = $item->metadata;
				$K2Item->metakey = $item->metakey;
				$K2Item->params = $itemParams;
				$K2Item->language = $item->language;
				$K2Item->check();
				if ($preserveItemIDs)
				{
					$K2Item->id = $item->id;
					$db->insertObject('#__k2_items', $K2Item);
				}
				else
				{
					$K2Item->store();
				}

				if (!empty($item->metakey))
				{
					$itemTags = explode(',', $item->metakey);
					foreach ($itemTags as $itemTag)
					{
						$itemTag = JString::trim($itemTag);
						if (in_array($itemTag, JArrayHelper::getColumn($tags, 'name')))
						{

							$query = "SELECT id FROM #__k2_tags WHERE name=".$db->Quote($itemTag);
							$db->setQuery($query);
							$id = $db->loadResult();
							$query = "INSERT INTO #__k2_tags_xref (`id`, `tagID`, `itemID`) VALUES (NULL, {$id}, {$K2Item->id})";
							$db->setQuery($query);
							$db->query();
						}
						else
						{
							$K2Tag = JTable::getInstance('K2Tag', 'Table');
							$K2Tag->name = $itemTag;
							$K2Tag->published = 1;
							$K2Tag->store();
							$tags[] = $K2Tag;
							$query = "INSERT INTO #__k2_tags_xref (`id`, `tagID`, `itemID`) VALUES (NULL, {$K2Tag->id}, {$K2Item->id})";
							$db->setQuery($query);
							$db->query();
						}
					}
				}
			}

		}

		foreach ($mapping as $oldID => $newID)
		{
			$query = "UPDATE #__k2_categories SET parent=".$newID." WHERE parent=".$oldID;
			$db->setQuery($query);
			$db->query();
		}
		$mainframe->enqueueMessage(JText::_('K2_IMPORT_COMPLETED'));
		$mainframe->redirect('index.php?option=com_k2&view=items');
	}

	function move()
	{

		$mainframe = JFactory::getApplication();
		$cid = JRequest::getVar('cid');
		$catid = JRequest::getInt('category');
		foreach ($cid as $id)
		{
			$row = JTable::getInstance('K2Item', 'Table');
			$row->load($id);
			$row->catid = $catid;
			$row->ordering = $row->getNextOrder('catid = '.$row->catid.' AND published = 1');
			$row->store();
		}
		$cache = JFactory::getCache('com_k2');
		$cache->clean();
		$mainframe->enqueueMessage(JText::_('K2_MOVE_COMPLETED'));
		$mainframe->redirect('index.php?option=com_k2&view=items');

	}

	function getItemsAuthors()
	{
		$db = $this->getDBO();
		$query = "SELECT id, name, block FROM #__users WHERE id IN(SELECT DISTINCT(created_by) FROM #__k2_items) ORDER BY name";
		$db->setQuery($query);
		$rows = $db->loadObjectList();
		return $rows;
	}

}

redpajama_set_name: RedPajamaGithub


text:
Friends bringing Portrait Coffee cafe, roastery to West End this fall
The Portrait Coffee team.
Credit: Contributed
By Yzusel
Aaron Fender has worked in the coffee industry for nearly 10 years, but it wasn't until recently that he decided, along with some friends, to launch his own caffeniated venture.
"I've seen every touch point of speciality coffee companies," Fender said. "We had a desire for representation in the industry."
Fender and his wife, Erin, partnered with John and Shawndra Onwuchekwa, Marcus Hollinger, Khalid Smith and Shawndra Onwuchekwa to launch a Kickstarter at the end of last year with an initial goal of raising $25,000 to launch Portrait Coffee, a cafe and roastery at 1065 Ralph David Abernathy Blvd. SW in the West End neighborhood. The team ended up raising more than $10,000 over their goal to launch the business.
The longtime friends see representation as an important part of Black-owned Portrait, which is slated to open this fall, Eater Atlanta first reported.
"Most people don't know that coffee was originally discovered by Africans," Fender said. "In a lot of ways, we've been Photoshopped out of the picture. There was the impetus for Portrait to reimagine the picture that comes to people's minds when it comes to specialty coffee."
The timing for opening poses some challenges due to the COVID-19 pandemic, Fender said, but in some ways "it's been a blessing in disguise," providing an opportunity to rethink what a place like Portrait can provide for the West End community and beyond.
Fender said he and his partners, who all live in the neighborhood, never considered any other area in which to plant their business roots.
"My wife grew up in the West End, and I got to learn the history through her," he said. "We only wanted to be in this neighborhood. There's such a history of Black excellence here."
The business is already offering its coffee to the public via sales on its website, as well as Portrait merch including "Pouring a New Narrative" shirts and totes. Also available is a coffee delivery club, with weekly, biweekly and monthly deliveries of 12 oz. bags of Portrait-roasted coffee.
The cafe, which will be on the top floor of the building with the roastery in the basement, will likely start out offering patio and to-go service only, eventually allowing customers to drink inside the 35-seat space. Drink options will include traditional coffee drinks and teas. as well as specialty beverages including the Aunt Viv, a brown sugar and cardamom latte. The drink was served during a Portrait pop-up at Old Fourth Ward coffee shop Chrome Yellow that raised money for Peace Preparatory Academy.
Also expect to see light bites for breakfast and lunch including breakfast sandwiches, paninis and toasts.
Ultimately, Fender said, a big goal of the business is to help bring continued positive attention to the West End.
"We want to continue the legacy, and shine a light on the incredible things happening in the community."
ExploreRestaurants opening soon in metro Atlanta
ExploreIntown Atlanta dining news
Superica opening in West Midtown and more restaurant news from the week
Beer Pick: Good Word Brewing's Scaling the Garden Wall Helles is smokin' good
Yeppa & Co. to bring Italian cuisine to Buckhead Village